Skip to content

Encoders_CreateInstanceForStreaming

function

Delphi
function Encoders_CreateInstanceForStreaming (OutputURL: string): LongInt;
C++Builder
System::LongInt __fastcall Encoders_CreateInstanceForStreaming(System::UnicodeString OutputURL);
C#
public int Encoders_CreateInstanceForStreaming(string OutputURL);
VB.NET
Public Function Encoders_CreateInstanceForStreaming(OutputURL As String) As Integer
C++/Qt
int Encoders_CreateInstanceForStreaming (wchar_t *OutputURL);

Adds a Datastead Encoder instance to the graph, to stream to a new destination.

Returns a unique ID for this encoder. This unique ID is required to invoke Encoder_SetInt, Encoder_GetInt, Encoder_SetStr, Encoder_Pause, Encoder_Resume, Encoder_NewOutputFile or Encoders_RemoveInstance.

The instance is used only once enabled with Encoder_SetInt: Enc_IsActive_bool = 1, plus Enc_Video_Enabled_bool = 1 and/or Enc_Audio_Enabled_bool = 1. TVideoGrabber is then started with StartPreview, which sends the audio/video samples to the active instances.

Invoke this function while the video is stopped. Returns -1 if the video is running or if the Datastead Multipurpose Encoder is not installed. If an instance already streams to the same URL, its ID is returned.

See Streaming through the Datastead Encoder.