From 0bef1160209c6974039c8c7fed4ae9e7b6fe3eca Mon Sep 17 00:00:00 2001 From: itsmattkc Date: Wed, 26 Feb 2020 11:35:44 +1100 Subject: [PATCH] oiiodecoder: set correct image stream Fixes bug where loading a saved project with still images could crash. --- app/codec/oiio/oiiodecoder.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/codec/oiio/oiiodecoder.cpp b/app/codec/oiio/oiiodecoder.cpp index 837946af0..271f2a688 100644 --- a/app/codec/oiio/oiiodecoder.cpp +++ b/app/codec/oiio/oiiodecoder.cpp @@ -83,6 +83,9 @@ bool OIIODecoder::Probe(Footage *f, const QAtomicInt *cancelled) image_stream->set_width(spec.width); image_stream->set_height(spec.height); + // Images will always have just one stream + image_stream->set_index(0); + // OIIO automatically premultiplies alpha // FIXME: We usually disassociate the alpha for the color management later, for 8-bit images this likely reduces the // fidelity?