Commit 2c4a567c by tofunmi Committed by Tofunmi Adigun-Hameed

Fix operations order in RenderingTest

For DefaultVideoFrameProcessorVideoFrameRenderingTest: `registerInputStream` sets the textureManager, so reordering makes sure the textureManager is set before you set the frame info. This is important for texture input, where the frame info provides the width and height.

PiperOrigin-RevId: 529753404
parent 75cde0aa
......@@ -345,11 +345,11 @@ public final class DefaultVideoFrameProcessorVideoFrameRenderingTest {
.submit(
() -> {
blankFrameProducer.configureGlObjects();
checkNotNull(defaultVideoFrameProcessor)
.setInputFrameInfo(new FrameInfo.Builder(WIDTH, HEIGHT).build());
// A frame needs to be registered despite not queuing any external input to ensure
// that the video frame processor knows about the stream offset.
defaultVideoFrameProcessor.registerInputStream(INPUT_TYPE_SURFACE);
checkNotNull(defaultVideoFrameProcessor).registerInputStream(INPUT_TYPE_SURFACE);
defaultVideoFrameProcessor.setInputFrameInfo(
new FrameInfo.Builder(WIDTH, HEIGHT).build());
defaultVideoFrameProcessor.registerInputFrame();
blankFrameProducer.produceBlankFramesAndQueueEndOfStream(inputPresentationTimesUs);
defaultVideoFrameProcessor.signalEndOfInput();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment