#include <vlc_plugin.h>
#include <vlc_demux.h>
#include <vlc_vout.h> /* vout_InitFormat */
+#include <assert.h>
/*****************************************************************************
* Module descriptor
add_integer( "rawvid-width", 0, 0, WIDTH_TEXT, WIDTH_LONGTEXT, 0 )
add_integer( "rawvid-height", 0, 0, HEIGHT_TEXT, HEIGHT_LONGTEXT, 0 )
add_string( "rawvid-chroma", NULL, NULL, CHROMA_TEXT, CHROMA_LONGTEXT,
- true );
+ true )
add_string( "rawvid-aspect-ratio", NULL, NULL,
- ASPECT_RATIO_TEXT, ASPECT_RATIO_LONGTEXT, true );
+ ASPECT_RATIO_TEXT, ASPECT_RATIO_LONGTEXT, true )
vlc_module_end ()
/*****************************************************************************
return VLC_SUCCESS;
error:
- if( p_sys )
- free( p_sys );
+ free( p_sys );
return VLC_EGENERIC;
}
{
demux_sys_t *p_sys = p_demux->p_sys;
- /* NB, demux_vaControlHelper only takes int for i_bps currently;
- * (2**31)-1 is insufficient to store 1080p50 4:4:4. */
- int64_t i_bps = 8LL * p_sys->frame_size * p_sys->pcr.i_divider_num
- / p_sys->pcr.i_divider_den;
+ /* (2**31)-1 is insufficient to store 1080p50 4:4:4. */
+ const int64_t i_bps = 8LL * p_sys->frame_size * p_sys->pcr.i_divider_num /
+ p_sys->pcr.i_divider_den;
/* XXX: DEMUX_SET_TIME is precise here */
return demux_vaControlHelper( p_demux->s, 0, -1, i_bps,
p_sys->frame_size, i_query, args );
}
+