diff --git a/spa/lib/video-raw.c b/spa/lib/video-raw.c index 3b122389e..618e97aba 100644 --- a/spa/lib/video-raw.c +++ b/spa/lib/video-raw.c @@ -506,8 +506,8 @@ spa_format_video_init (SpaMediaType type, static const SpaVideoInfoRaw default_raw_info = { SPA_VIDEO_FORMAT_UNKNOWN, { 320, 240 }, - { 1, 25 }, - { 1, 25 }, + { 25, 1 }, + { 25, 1 }, 1, SPA_VIDEO_INTERLACE_MODE_PROGRESSIVE, { 1, 1}, @@ -536,8 +536,8 @@ spa_format_video_init (SpaMediaType type, }; static const SpaVideoInfoH264 default_h264_info = { { 320, 240 }, - { 1, 25 }, - { 1, 25 } + { 25, 1 }, + { 25, 1 } }; prop_info = h264_prop_info; n_prop_info = SPA_N_ELEMENTS (h264_prop_info); @@ -556,8 +556,8 @@ spa_format_video_init (SpaMediaType type, }; static const SpaVideoInfoMJPG default_mjpg_info = { { 320, 240 }, - { 1, 25 }, - { 1, 25 } + { 25, 1 }, + { 25, 1 } }; prop_info = mjpg_prop_info; n_prop_info = SPA_N_ELEMENTS (mjpg_prop_info); diff --git a/spa/plugins/videotestsrc/videotestsrc.c b/spa/plugins/videotestsrc/videotestsrc.c index 2016a7ad0..064241549 100644 --- a/spa/plugins/videotestsrc/videotestsrc.c +++ b/spa/plugins/videotestsrc/videotestsrc.c @@ -32,8 +32,8 @@ #include #include -#define FRAMES_TO_TIME(this,f) ((this->current_format.info.raw.framerate.num * (f) * SPA_NSEC_PER_SEC) / \ - (this->current_format.info.raw.framerate.denom)) +#define FRAMES_TO_TIME(this,f) ((this->current_format.info.raw.framerate.denom * (f) * SPA_NSEC_PER_SEC) / \ + (this->current_format.info.raw.framerate.num)) #define STATE_GET_IMAGE_WIDTH(this) this->current_format.info.raw.size.width #define STATE_GET_IMAGE_HEIGHT(this) this->current_format.info.raw.size.height