CCodec: skip first N longest work inside total delay
If the client pauses pushing input to the component, work items inside
total delay may sit in the pipeline indefinitely. We don't want to
error out for those work. Once the client pushes EOS, ensure all work
items finishes within reasonable time regardless of delay.
Bug: 124355114
Test: manual
Test: atest CtsSecurityTestCases:StagefrightTest
Test: atest CtsMediaTestCases -- --module-arg CtsMediaTestCases:size:small
Change-Id: I0e95b2ddb94482da855d70cbe75f6bffaaffe279
diff --git a/media/codec2/sfplugin/PipelineWatcher.h b/media/codec2/sfplugin/PipelineWatcher.h
index ce82298..1c127e4 100644
--- a/media/codec2/sfplugin/PipelineWatcher.h
+++ b/media/codec2/sfplugin/PipelineWatcher.h
@@ -54,7 +54,7 @@
void flush();
bool pipelineFull() const;
- Clock::duration elapsed(const Clock::time_point &now) const;
+ Clock::duration elapsed(const Clock::time_point &now, size_t n) const;
private:
uint32_t mInputDelay;