Archived issue #0023813
TKOpenGl, OpenGl_Texture ignores stride image property
Description
Texture could be loaded incorrectly if rows in image are packed with padding bytes for alignment (Image_PixMap::SizeRowBytes()) or their order was specified from top-to-down rather than bottom-to-top (Image_PixMap::IsTopDown()).
Steps to reproduce
# This scenario reproduces problem with wrong dimensions pload MODELING pload VISUALIZATION box b 1 2 3 vinit vsetdispmode 1 vdisplay b vfit vdump texture_409.png rgb 409 409 vdump texture_412.png rgb 412 412 # texture loaded correctly vtexture b texture_412.png # texture is corrupted during uploading to OpenGL vtexture b texture_409.png
Public activity
4 archived notes
Participants are labeled by their role within this record.
Patch is ready for review in CR23813 branch (based on CR24392 branch).
Dear Commenter 1,
The branch is reviewed without remarks.
Please test.
The branch is reviewed without remarks.
Please test.
Dear Commenter 1,
Branch CR23813 (and products from GIT master) was compiled on Linux and Windows platforms and tested.
[revision removed]
Number of compiler warnings:
occt component :
Linux: 320 (320 on master)
Windows: 0 (0 on master)
products component :
Linux: 188 (188 on master)
Windows: 286 (286 on master)
Regressions/Differences:
No regressions/differences
Testing cases:
bugs vis bug23813 - OK
Testing on Linux:
Total MEMORY difference: 358409872 / 358543144
Total CPU difference: 43218.369999999966 / 43977.48000000039
Testing on Windows:
Total MEMORY difference: 413033320 / 412727724
Total CPU difference: 32455.953125 / 32189.140625
There is difference in images found by testdiff:
IMAGE bugs vis bug9517: bug9517_Driver1_Viewer1_View1.png differs
http://occt-tests/CR23813-master-occt/Debian60-64/diff-Debian60-64.html
http://occt-tests/CR23813-master-occt/Windows-32-VC9/diff-Windows-32-VC9.html
Branch CR23813 (and products from GIT master) was compiled on Linux and Windows platforms and tested.
[revision removed]
Number of compiler warnings:
occt component :
Linux: 320 (320 on master)
Windows: 0 (0 on master)
products component :
Linux: 188 (188 on master)
Windows: 286 (286 on master)
Regressions/Differences:
No regressions/differences
Testing cases:
bugs vis bug23813 - OK
Testing on Linux:
Total MEMORY difference: 358409872 / 358543144
Total CPU difference: 43218.369999999966 / 43977.48000000039
Testing on Windows:
Total MEMORY difference: 413033320 / 412727724
Total CPU difference: 32455.953125 / 32189.140625
There is difference in images found by testdiff:
IMAGE bugs vis bug9517: bug9517_Driver1_Viewer1_View1.png differs
http://occt-tests/CR23813-master-occt/Debian60-64/diff-Debian60-64.html
http://occt-tests/CR23813-master-occt/Windows-32-VC9/diff-Windows-32-VC9.html
Dear Commenter 1
> IMAGE bugs vis bug9517: bug9517_Driver1_Viewer1_View1.png differs
This is an improvement (for regression which has not been reported) - see original issue #0009517, image now looks correctly.
> IMAGE bugs vis bug9517: bug9517_Driver1_Viewer1_View1.png differs
This is an improvement (for regression which has not been reported) - see original issue #0009517, image now looks correctly.
Related records