ff-save: move a static flag to private data

This makes gegl:ff-save possible to use in applications saving many different
container types.
parent 2216bff6
......@@ -130,6 +130,8 @@ typedef struct
long audio_read_pos;
int next_apts;
int file_inited;
} Priv;
static void
......@@ -970,7 +972,6 @@ process (GeglOperation *operation,
{
GeglProperties *o = GEGL_PROPERTIES (operation);
Priv *p = (Priv*)o->user_data;
static gint inited = 0;
g_assert (input);
......@@ -982,10 +983,10 @@ process (GeglOperation *operation,
p->height = result->height;
p->input = input;
if (!inited)
if (!p->file_inited)
{
tfile (o);
inited = 1;
p->file_inited = 1;
}
write_video_frame (o, p->oc, p->video_st);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment