////////////////////////////////////////////////////////////////////////// // // Copyright (C) 2007-2020 , Inc. All Rights Reserved. // ////////////////////////////////////////////////////////////////////////// using System; using UnityEngine; namespace GCSeries.zView { /// /// Abstract class to derive from when implementing a custom virtual /// camera for a supported zView mode. /// public abstract class VirtualCamera : MonoBehaviour { /// /// Set up the VirtualCamera. /// /// /// /// Performs any setup related operations specific to the mode the /// VirtualCamera is associated with. This method will be called once /// per ModeSetupPhase when the specified connection has transitioned /// to the ConnectionState.ModeSetup state. /// /// /// /// A reference to the zView API Monobehaviour script. /// /// /// The connection to perform the VirtualCamera's setup phase for. /// /// /// The mode setup phase for the specified connection. /// public abstract void SetUp(ZView zView, IntPtr connection, ZView.ModeSetupPhase phase); /// /// Tear down the VirtualCamera. /// /// /// /// Performs any cleanup related operations specific to the mode the /// VirtualCamera is associated with. /// public abstract void TearDown(); /// /// Render a single frame. /// /// /// /// A reference to the zView API Monobehaviour script. /// /// /// The connection to perform the VirtualCamera's render for. /// /// /// The received frame from the specified connection. /// public abstract void Render(ZView zView, IntPtr connection, IntPtr receivedFrame); /// /// Get the native texture pointer associated with the VirtualCamera's /// offscreen render texture. /// /// /// /// The native texture pointer associated with the VirtualCamera's offscreen /// render texture. /// public abstract IntPtr GetNativeTexturePtr(); } }