Theora.core.beginVideo

From GiderosMobile
Revision as of 22:02, 13 November 2026 by MoKaLux (talk | contribs) (Created page with "__NOTOC__ '''Available since:''' Gideros 2017.10<br/> '''Class:''' Ogg<br/> === Description === Starts the video encoder of an encoding (recording) stream. <syntaxhighlig...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Available since: Gideros 2017.10
Class: Ogg

Description

Starts the video encoder of an encoding (recording) stream.

theora.core.beginVideo(streamId,codec,frameRate,width,height,format,quality)

The video header is written into the same file as the audio stream, so beginVideo() must be called before the first audio packet is encoded.

Parameters

streamId: (number) stream id of the recording sound, for example mic:getStreamId()
codec: (string) codec name, "theora"
frameRate: (number) frames per second, for example 30
width: (number) frame width, must be a multiple of 16
height: (number) frame height, must be a multiple of 16
format: (number) image format, 3 (YUV420) is the only supported value
quality: (number) encoder quality from 0 to 1, for example 0.6