docs.unity3d.com
    Show / Hide Table of Contents

    Class ScreenCapture

    Inheritance
    Object
    BaseLogger
    ScreenCapture
    Inherited Members
    BaseLogger._type
    BaseLogger._userPath
    BaseLogger._name
    BaseLogger._extension
    BaseLogger._sequence
    BaseLogger._suffixAction
    BaseLogger._loggerSuffixOption
    BaseLogger.SetOutputPath(String, String, String, String, Func<String>, LoggerSuffixOption)
    BaseLogger.GetPath()
    Namespace: Unity.Simulation
    Syntax
    public class ScreenCapture : BaseLogger

    Constructors

    ScreenCapture(String)

    Declaration
    public ScreenCapture(string capturePath = "")
    Parameters
    Type Name Description
    String capturePath

    Methods

    ScreenCaptureAsync<T>(Camera, GraphicsFormat, String, CaptureImageEncoder.ImageFormat)

    Capture Screenshot asynchronously for a given source camera

    Declaration
    public void ScreenCaptureAsync<T>(Camera sourceCamera, GraphicsFormat renderTextureFormat, string path, CaptureImageEncoder.ImageFormat format = CaptureImageEncoder.ImageFormat.Raw)
        where T : struct
    Parameters
    Type Name Description
    Camera sourceCamera

    Source camera for which the screen capture is to be performed

    GraphicsFormat renderTextureFormat

    Render Texture format for the screen capture

    String path

    Path where the image is to be saved

    CaptureImageEncoder.ImageFormat format

    Image format in which the file is to be saved. Default is set to RAW

    Type Parameters
    Name Description
    T
    Back to top
    Terms of use
    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