Skip to content

Commit 7d75d1a

Browse files
committed
Fixed undefined variable error
1 parent 78268fa commit 7d75d1a

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/ffmpegio/streams/SimpleStreams.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -220,6 +220,7 @@ def _finalize(self, ffmpeg_args):
220220
has_fg = configure.has_filtergraph(ffmpeg_args, "video")
221221

222222
pix_fmt = outopts.get("pix_fmt", None)
223+
pix_fmt_in = s_in = r_in = None
223224
if (
224225
pix_fmt is None
225226
and not has_fg
@@ -234,8 +235,7 @@ def _finalize(self, ffmpeg_args):
234235
r_in = info["frame_rate"]
235236
except:
236237
pix_fmt_in = 'rgb24'
237-
else:
238-
pix_fmt_in = s_in = r_in = None
238+
239239

240240
if pix_fmt_in is None and pix_fmt is None:
241241
raise ValueError("pix_fmt must be specified.")

0 commit comments

Comments
 (0)