AcademySoftwareFoundation / AcademySoftwareFoundation/OpenImageIO
[BUG] When using ImageBuf, this file reports a divide-by-zero exception error. Please take a look
- Dominant language
- C++
- Stars
- 2.4k
- Forks
- 698
- Avg merge
- 2d 23h
- Merged PRs (30d)
- 46
Description
**Describe the bug**
When using ImageBuf, this file reports a divide-by-zero exception error. Please take a look
This is a sample file.
[XPPen_new_logo.zip](https://github.com/AcademySoftwareFoundation/OpenImageIO/files/14567847/XPPen_new_logo.zip)
**OpenImageIO version and dependencies**
v2.4.13.0
**To Reproduce**
Execute the following code:
```
ImageCache *cache = ImageCache::create ()
auto inp = ImageBuf(path, cache);
if (inp.has_error()) {
std::cout << "parser: open image error: " << inp.geterror() << std::endl;
return nullptr;
}
```
**Evidence**

Contributor guide
Research direction
Reproduce the failure with the attached XPPen_new_logo.zip using the ImageCache and ImageBuf snippet in the issue. Start by tracing the ImageBuf construction and the reported divide-by-zero error in OpenImageIO v2.4.13.0. Done means the sample no longer produces the divide-by-zero exception and image-open errors remain appropriately reported.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- computer-graphics
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100