#define LT_CHROMA N_("Output chroma for the memory image as a 4-character " \
"string, eg. \"RV32\".")
-#define INVMEM_HELP N_( "This module make possible making video stream from raw-image " \
- "generating (to memory) from rendering program uses libvlc. " \
- "To use this module from libvlc set --codec to invmem, "\
- "set all --invmem-* options in vlc_argv an use " \
- "libvlc_media_new(libvlc, \"fake://\", &ex);. " \
- "Besides is simillar to vmem video output module." )
-
vlc_module_begin()
set_category( CAT_INPUT )
set_subcategory( SUBCAT_INPUT_VCODEC )
set_shortname( N_("Memory video decoder") )
set_description( N_("Memory video decoder") )
- set_help( INVMEM_HELP )
set_capability( "decoder", 50 )
set_callbacks( OpenDecoder, CloseDecoder )
add_shortcut( "invmem" )
p_dec->fmt_out.i_codec = chroma;
p_dec->fmt_out.video.i_width = p_dec->p_sys->i_width;
p_dec->fmt_out.video.i_height = p_dec->p_sys->i_height;
- p_dec->fmt_out.video.i_aspect = VOUT_ASPECT_FACTOR * p_dec->p_sys->i_width / p_dec->p_sys->i_height;
+ p_dec->fmt_out.video.i_sar_num = 1;
+ p_dec->fmt_out.video.i_sar_den = 1;
p_dec->fmt_out.i_cat = VIDEO_ES;
p_sys->i_pitch = pitch;
if ( !p_pic ) return NULL;
p_pic->b_force = true;
p_pic->p->i_pitch = p_dec->p_sys->i_pitch;
- p_pic->date = p_block->i_pts > 0 ? p_block->i_pts : p_block->i_dts;
+ p_pic->date = p_block->i_pts > VLC_TS_INVALID ? p_block->i_pts : p_block->i_dts;
// lock input and copy to picture
p_pic->p->p_pixels = p_sys->pf_lock( p_dec->p_sys->p_data );