|
| ProGifRecorder (Camera camera=null) |
|
void | Setup (bool autoAspect, int width, int height, int fps, float recorderTime, int repeat, int quality) |
| Initializes the component. Use this if you need to change the recorder settings in a script. This will flush the previously saved frames as settings can't be changed while recording.
|
|
void | Setup (Vector2 gifAspectRatio, int width, int height, int fps, float recorderTime, int repeat, int quality) |
| Initializes the component. Use this if you need to change the recorder settings in a script. This will flush the previously saved frames as settings can't be changed while recording. (Use this Setup if you need to crop the image to a specify aspect ratio. The pixels out of the provided aspect ratio will be cut.)
|
|
RenderTexture | GetTexture (int index=-1) |
| Gets a stored texture by index in the texture list (You can use it as the preview for displaying on a RawImage/Renderer).
|
|
void | SetGifRotation (ImageRotator.Rotation rotation) |
| Set the GIF rotation (Support rotate 0, -90, 90, 180 degrees).
|
|
void | SetGifAspectRatio (Vector2 gifAspectRatio) |
| Set the gif aspect ratio.
|
|
void | SetOverrideFrameDelay (float frameDelayInSeconds) |
| Set the new frame delay to override the FPS(m_FramePerSecond).
|
|
void | SetTransparent (Color32 color32, byte transparentColorRange) |
| Sets the transparent color, hide this color in the GIF. The GIF specification allows setting a color to be transparent. *** Use case: if you want to record gameObject, character or anything else with transparent background, please make sure the background is of solid color(no gradient), and the target object do not contain this color. (Also be reminded, the transparent feature takes more time to encode the GIF)
|
|
void | SetTransparent (bool autoDetectTransparent) |
| Auto detects the input image(s) pixels for enable/disable transparent feature. *** Use case: for pre-made images that have transparent pixels manually set. (Also be reminded, the transparent feature takes more time to encode the GIF)
|
|
void | Pause () |
| Pauses recording.
|
|
void | Resume () |
| Resume recording.
|
|
void | Record (Action onDurationEnd) |
| Starts or resumes recording. You can't resume while it's pre-processing data to be saved.
|
|
void | Stop () |
| Stops the recording. You can't resume the record after it has been stopped. You can save gif or start a new recording.
|
|
void | FlushMemory () |
| Clears all saved frames from memory and starts fresh.
|
|
void | Save () |
| Saves the stored frames to a gif file. The filename will automatically be generated. Recording will be paused and won't resume automatically. You can use the.
|
|
void | Save (string filename) |
| Saves the stored frames to a gif file. If the filename is null or empty, an unique one will be generated. You don't need to add the .gif extension to the name. Recording will be paused and won't resume automatically. You can use the.
|
|
void | ForceSetFrames (Queue< RenderTexture > renderTextures) |
| Force assign frames(RenderTexture) to this recorder. This will clear all previous stored frames first.
|
|
void | SetOnRecordAction (Action< float > onRecordAction) |
|
void | Clear () |
| Clear and Remove the ProGifRecorderComponent from camera.
|
|
void ProGifRecorder.SetTransparent |
( |
Color32 |
color32, |
|
|
byte |
transparentColorRange |
|
) |
| |
|
inline |
Sets the transparent color, hide this color in the GIF. The GIF specification allows setting a color to be transparent. *** Use case: if you want to record gameObject, character or anything else with transparent background, please make sure the background is of solid color(no gradient), and the target object do not contain this color. (Also be reminded, the transparent feature takes more time to encode the GIF)
- Parameters
-
color32 | The Color to hide in the gif. Make sure the alpha value greater than Zero, else disable the transparent feature. |
transparentColorRange | The range of RGB value for picking nearby colors of the input color to set as transparent pixels. |