int64 requestFrame(int64 frame) { int64 currentFrame; GstFormat format = GST_FORMAT_DEFAULT; gst_element_seek(pipeline, 1.0, format, (GstSeekFlags)(GST_SEEK_FLAG_KEY_UNIT | GST_SEEK_FLAG_FLUSH), GST_SEEK_TYPE_SET, frame, GST_SEEK_TYPE_NONE, -1); gst_element_query_position(pipeline, &format, ¤tFrame); return currentFrame; }