Skip to content

Commit 48c3e22

Browse files
committed
fix: gif output didn't handle FramesPerSecond attribute correctly (#4890)
The version of open that takes an array of subimage specs didn't use them properly for finding the FramesPerSecond hint (or the ioproxy!). Fixes #3716 Signed-off-by: Larry Gritz <[email protected]>
1 parent 6c445c0 commit 48c3e22

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/gif.imageio/gifoutput.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -155,10 +155,10 @@ GIFOutput::open(const std::string& name, int subimages, const ImageSpec* specs)
155155
m_subimage = 0;
156156
m_nsubimages = subimages;
157157
m_subimagespecs.assign(specs, specs + subimages);
158-
float fps = m_spec.get_float_attribute("FramesPerSecond", 1.0f);
158+
float fps = specs[0].get_float_attribute("FramesPerSecond", 1.0f);
159159
m_delay = (fps == 0.0f ? 0 : (int)(100.0f / fps));
160160

161-
ioproxy_retrieve_from_config(m_spec);
161+
ioproxy_retrieve_from_config(specs[0]);
162162
if (!ioproxy_use_or_open(name))
163163
return false;
164164

0 commit comments

Comments
 (0)