-
Notifications
You must be signed in to change notification settings - Fork 568
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] Incorrect subimages for TX files #2719
Comments
Yes, I can reproduce. Looking into it... |
A combination of a bug and a misunderstanding. When a TIFF file is found to contain the tag The full signature of the spec() function is: I can't tell if you (a) want to walk through what OIIO considers subimages, and expect to see just ONE (which will have many MIP levels, but you aren't iterating over those in your example); or (b) if you want to walk through the MIP levels. If (b), then you want your loop to look like this:
However, if you really did want (a), then you are doing it correctly and there is a bug -- totally my fault -- in ImageInput::spec(), in the specific case where it's a "mip-mapped" TIFF file but you are passing an invalid subimage request. I will post a patch immediately, stay tuned... |
Proposed fix: #2723 |
(a) is right :) |
Describe the bug
Traversing subimages in TX files (multipage TIF) cause an infinitive loop.
It is not returning a correct ImageSpec for the given page.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
It works correctly for multipart EXRs - the loop ends by returning OIIO::TypeUnknown format if subimage not exists.
It also looks that the spec is not updated after calling
in->spec(++subimage)
Evidence
normal.zip
Platform information:
The text was updated successfully, but these errors were encountered: