Accelerate the thumbnail extraction when the sync-frame duration is long

BZ: 58036

When the sync frame duration is very long in the test clips, the
thumbnail extration will be very slow. Because the program will
have to decode from the previous sync-frame to the desired frame.
If end user presses the exit button before the thumbnail
extraction finishes, sometimes ANR will happen.

In this patch, if the desized frame's timestamp is 3secs larger
than the previous sync-frame, we will choose to use the sync-frame
as the thumbnail.

Change-Id: Ia6c2f31fce13bb0af35f4c72cd8600f3540d87c3
Signed-off-by: wfeng6 <wei.feng@intel.com>
Reviewed-on: http://android.intel.com:8080/70550
Reviewed-by: Guo, Nana N <nana.n.guo@intel.com>
Reviewed-by: Tang, Richard <richard.tang@intel.com>
Reviewed-by: Jiang, Fei <fei.jiang@intel.com>
Reviewed-by: Chen, Tianmi <tianmi.chen@intel.com>
Reviewed-by: Ding, Haitao <haitao.ding@intel.com>
Tested-by: Ding, Haitao <haitao.ding@intel.com>
Reviewed-by: buildbot <buildbot@intel.com>
Tested-by: buildbot <buildbot@intel.com>
1 file changed