OutputFrameBuffer Class

Description

输出帧缓存。

有一个输出帧输入端口和输出帧获取函数,用于将输出帧的获取方式从异步转化为同步轮询,适合逐帧渲染。

OutputFrameBuffer占用1个camera的buffer。应使用camera的setBufferCapacity设置不少于所有组件占用的camera的buffer数量。参考 概览 _ 。

本类的所有成员都是线程安全的。

input

输入端口。

C: void easyar_OutputFrameBuffer_input(easyar_OutputFrameBuffer * This, easyar_OutputFrameSink * * Return)
C++17: std::shared_ptr<OutputFrameSink> input()
Traditional C++: void input(OutputFrameSink * * Return)
Java: public @Nonnull OutputFrameSink input()
Kotlin: fun input(): OutputFrameSink
Objective-C: - (easyar_OutputFrameSink *)input
Swift: public func input() -> OutputFrameSink
C#: public virtual OutputFrameSink input()

bufferRequirement

当前组件占用camera buffer的数量。

C: int easyar_OutputFrameBuffer_bufferRequirement(easyar_OutputFrameBuffer * This)
C++17: int bufferRequirement()
Traditional C++: int bufferRequirement()
Java: public int bufferRequirement()
Kotlin: fun bufferRequirement(): Int
Objective-C: - (int)bufferRequirement
Swift: public func bufferRequirement() -> Int32
C#: public virtual int bufferRequirement()

signalOutput

到达信号输出端口。可用于连接 InputFrameThrottler.signalInput

C: void easyar_OutputFrameBuffer_signalOutput(easyar_OutputFrameBuffer * This, easyar_SignalSource * * Return)
C++17: std::shared_ptr<SignalSource> signalOutput()
Traditional C++: void signalOutput(SignalSource * * Return)
Java: public @Nonnull SignalSource signalOutput()
Kotlin: fun signalOutput(): SignalSource
Objective-C: - (easyar_SignalSource *)signalOutput
Swift: public func signalOutput() -> SignalSource
C#: public virtual SignalSource signalOutput()

peek

获取最新的 OutputFrame

C: void easyar_OutputFrameBuffer_peek(easyar_OutputFrameBuffer * This, easyar_OptionalOfOutputFrame * Return)
C++17: std::optional<std::shared_ptr<OutputFrame>> peek()
Traditional C++: void peek(OutputFrame * * Return)
Java: public @Nullable OutputFrame peek()
Kotlin: fun peek(): OutputFrame?
Objective-C: - (easyar_OutputFrame *)peek
Swift: public func peek() -> OutputFrame?
C#: public virtual Optional<OutputFrame> peek()

create

创建。

C: void easyar_OutputFrameBuffer_create(easyar_OutputFrameBuffer * * Return)
C++17: static std::shared_ptr<OutputFrameBuffer> create()
Traditional C++: static void create(OutputFrameBuffer * * Return)
Java: public static @Nonnull OutputFrameBuffer create()
Kotlin: companion object fun create(): OutputFrameBuffer
Objective-C: + (easyar_OutputFrameBuffer *)create
Swift: public static func create() -> OutputFrameBuffer
C#: public static OutputFrameBuffer create()

pause

暂停输出 OutputFrame 。执行之后, OutputFrameBuffer.peek 的结果均为空。 OutputFrameBuffer.signalOutput 不受影响。

C: void easyar_OutputFrameBuffer_pause(easyar_OutputFrameBuffer * This)
C++17: void pause()
Traditional C++: void pause()
Java: public void pause()
Kotlin: fun pause(): Unit
Objective-C: - (void)pause
Swift: public func pause() -> Void
C#: public virtual void pause()

resume

继续输出 OutputFrame

C: void easyar_OutputFrameBuffer_resume(easyar_OutputFrameBuffer * This)
C++17: void resume()
Traditional C++: void resume()
Java: public void resume()
Kotlin: fun resume(): Unit
Objective-C: - (void)resume
Swift: public func resume() -> Void
C#: public virtual void resume()