Show / Hide Table of Contents

Class ScreenshotManager

Screenshot manager class.

Take some awesome screenies with this!

Inheritance
System.Object
ScreenshotManager
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: GlitchedPolygons.Utilities
Assembly: UnityScriptsLibrary.dll
Syntax
public static class ScreenshotManager

Methods

| Improve this Doc View Source

GetScreenshotFromCamera(Camera, Int32, Int32)

This returns the raw pixels byte array of a screenshot taken from a specific Camera.

You can then use the Texture2D.Load(byte[] image) extension method to load the byte array into a usable texture image.

Declaration
public static byte[] GetScreenshotFromCamera(Camera screenshotCamera, int screenshotWidth = 800, int screenshotHeight = 450)
Parameters
Type Name Description
Camera screenshotCamera

The camera through which the screenshot shall be taken.

System.Int32 screenshotWidth

The width of the screenshot (in pixels).

System.Int32 screenshotHeight

The height of the screenshot (in pixels).

Returns
Type Description
System.Byte[]

The resulting byte[] array of the screenshot image.

  • Improve this Doc
  • View Source
Back to top Generated by DocFX