docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method AddVideoFrame

    AddVideoFrame(RenderTexture, MediaTime)

    Encodes a Texture and adds it to the video stream.

    Declaration
    void AddVideoFrame(RenderTexture frame, MediaTime time)
    Parameters
    Type Name Description
    RenderTexture frame

    The texture to encode.

    MediaTime time

    The timestamp of the current frame.

    AddVideoFrame(NativeArray<byte>, MediaTime)

    Encodes an array of bytes and adds it to the video stream.

    Declaration
    void AddVideoFrame(NativeArray<byte> bytes, MediaTime time)
    Parameters
    Type Name Description
    NativeArray<byte> bytes

    The array of bytes to encode.

    MediaTime time

    The timestamp of the current frame.

    Remarks

    The encoder interprets the format of the array based on the texture format in IEncoderSettings passed to the OpenStream method.

    See Also
    OpenStream(IEncoderSettings, RecordingContext)
    In This Article
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023