Skip to content

Commit

Permalink
mmal: increase decode buffering a little to help harder MVC files
Browse files Browse the repository at this point in the history
PR8610 reduced buffering in codec which generally improved behaviour,
but we have some reports of hard streams (like 3D BluRay) that now
lag. The problem is when the codec's input buffer runs dry you
waste useful decoder cycles. It seems adding another two frames of
latency to decoder gets the performance back.
  • Loading branch information
popcornmix committed Feb 19, 2016
1 parent 0aaca6c commit 125bb30
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion xbmc/cores/VideoPlayer/DVDCodecs/Video/MMALCodec.cpp
Expand Up @@ -676,7 +676,7 @@ bool CMMALVideo::Open(CDVDStreamInfo &hints, CDVDCodecOptions &options)

// limit number of callback structures in video_decode to reduce latency. Too low and video hangs.
// negative numbers have special meaning. -1=size of DPB -2=size of DPB+1
status = mmal_port_parameter_set_uint32(m_dec_input, MMAL_PARAMETER_VIDEO_MAX_NUM_CALLBACKS, -3);
status = mmal_port_parameter_set_uint32(m_dec_input, MMAL_PARAMETER_VIDEO_MAX_NUM_CALLBACKS, -5);
if (status != MMAL_SUCCESS)
CLog::Log(LOGERROR, "%s::%s Failed to configure max num callbacks on %s (status=%x %s)", CLASSNAME, __func__, m_dec_input->name, status, mmal_status_to_string(status));

Expand Down

0 comments on commit 125bb30

Please sign in to comment.