Class BaseRenderCapturer
An abstract MonoBehaviour class for capturing the render result of another component and writing it to disk as a texture
Inherited Members
Namespace: Unity.StreamingImageSequence
Syntax
public abstract class BaseRenderCapturer : MonoBehaviour
Fields
m_rt
Declaration
protected RenderTexture m_rt
Field Value
Type | Description |
---|---|
RenderTexture |
Methods
BeginCapture()
Prepare the component for capturing. May require several frames
Declaration
public abstract IEnumerator BeginCapture()
Returns
Type | Description |
---|---|
IEnumerator | The current position of the begin process |
CanCapture()
Can the capturer perform the capturing process
Declaration
public abstract bool CanCapture()
Returns
Type | Description |
---|---|
Boolean | True if capturing can be executed, false otherwise |
CaptureToFile(String)
Capture the contents of RenderTexture into file
Declaration
public void CaptureToFile(string outputFilePath)
Parameters
Type | Name | Description |
---|---|---|
String | outputFilePath | The path of the file |
EndCapture()
Clean up the component after capturing
Declaration
public abstract void EndCapture()
GetInternalTexture()
Gets the internal texture used for the capturing process
Declaration
public Texture GetInternalTexture()
Returns
Type | Description |
---|---|
Texture | The internal texture |
GetLastErrorMessage()
Get the last error message.
Declaration
public string GetLastErrorMessage()
Returns
Type | Description |
---|---|
String | The last error message |
ReleaseRenderTexture()
Release Render Texture
Declaration
protected void ReleaseRenderTexture()
SetErrorMessage(String)
Declaration
protected void SetErrorMessage(string err)
Parameters
Type | Name | Description |
---|---|---|
String | err |
UpdateRenderTexture()
Updates the render texture used for the capturing process
Declaration
protected abstract RenderTexture UpdateRenderTexture()
Returns
Type | Description |
---|---|
RenderTexture | The updated render texture |