AVBlocks for .NET  2.3
Audio and Video Software Development Kit
Block Class Referenceabstract

Provides functionality for audio and video encoding, decoding and transforming. More...

Inheritance diagram for Block:
MediaInfo Transcoder

Public Member Functions

abstract void Close ()
 Closes the Block. More...
 
abstract void Dispose ()
 Disposes the Block and reclaims the resources used by the object. More...
 
abstract bool EndOfStream (int inputIndex)
 Tells the Block that there's no more data for the specified input socket. More...
 
abstract bool Flush ()
 Flushes the data buffered in the Block to the output. More...
 
abstract bool Open ()
 Initializes the Block based on the specified input and desired output. More...
 
abstract bool Pull (out int outputIndex, MediaSample outputSample)
 Pulls output data from the Block. More...
 
abstract bool PullUnmanaged (out int outputIndex, MediaSample outputSample)
 Pulls output data from the Block. More...
 
abstract bool Push (int inputIndex, MediaSample inputSample)
 Pushes input data to the Blocks. More...
 
abstract bool PushUnmanaged (int inputIndex, MediaSample inputSample)
 Pushes input data to the Block. More...
 

Properties

abstract ErrorInfo Error [get]
 The error information for the last block operation. More...
 
abstract MediaSocketList Inputs [get]
 A modifiable collection of MediaSocket objects which describe the input data of the Block. More...
 
abstract MediaSocketList Outputs [get]
 A modifiable collection of MediaSocket objects which describe the output data of the Blocks. More...
 

Detailed Description

Provides functionality for audio and video encoding, decoding and transforming.

See also
Transcoder

Member Function Documentation

abstract void Close ( )
pure virtual

Closes the Block.

When closed it can neither accept, nor deliver data.

Implemented in MediaInfo, and Transcoder.

abstract void Dispose ( )
pure virtual

Disposes the Block and reclaims the resources used by the object.

Implemented in Transcoder, and MediaInfo.

abstract bool EndOfStream ( int  inputIndex)
pure virtual

Tells the Block that there's no more data for the specified input socket.

Parameters
inputIndexSpecifies the index of the input socket for which there's no more data.
Returns
true if the operation is sucessfull; otherwise false.

Implemented in MediaInfo, and Transcoder.

abstract bool Flush ( )
pure virtual

Flushes the data buffered in the Block to the output.

Returns
true if the buffered data is sucessfully flushed; otherwise false.

Implemented in MediaInfo, and Transcoder.

abstract bool Open ( )
pure virtual

Initializes the Block based on the specified input and desired output.

Returns
true if the Block is sucessfully initialized and is ready to process data; otherwise false.

Implemented in MediaInfo, and Transcoder.

abstract bool Pull ( out int  outputIndex,
MediaSample  outputSample 
)
pure virtual

Pulls output data from the Block.

Parameters
outputIndexReturns the index of the output socket to which the data belongs.
outputSampleThe MediaSample object receives the output data in the MediaBuffer property.
Returns
true if the Block has successfully generated output, otherwise false.

Implemented in MediaInfo, and Transcoder.

abstract bool PullUnmanaged ( out int  outputIndex,
MediaSample  outputSample 
)
pure virtual

Pulls output data from the Block.

Parameters
outputIndexReturns the index of the output socket to which the data belongs.
outputSampleThe MediaSample object receives the output data in the UnmanagedMediaBuffer property.
Returns
true if the Block has successfully generated output, otherwise false.

Implemented in MediaInfo, and Transcoder.

abstract bool Push ( int  inputIndex,
MediaSample  inputSample 
)
pure virtual

Pushes input data to the Blocks.

Parameters
inputIndexSpecifies the index of the input socket whose data is pushed to the Block.
inputSampleA MediaSample object that contains the input data in the MediaBuffer property.
Returns
true when the Block has successfully processed the input data, otherwise false.

Implemented in MediaInfo, and Transcoder.

abstract bool PushUnmanaged ( int  inputIndex,
MediaSample  inputSample 
)
pure virtual

Pushes input data to the Block.

Parameters
inputIndexSpecifies the index of the input socket whose data is pushed to the Block.
inputSampleA MediaSample object that contains the input data in the UnmanagedMediaBuffer property.
Returns
true when the Block has successfully processed the input data, otherwise false.

Implemented in MediaInfo, and Transcoder.

Property Documentation

abstract ErrorInfo Error
get

The error information for the last block operation.

abstract MediaSocketList Inputs
get

A modifiable collection of MediaSocket objects which describe the input data of the Block.

abstract MediaSocketList Outputs
get

A modifiable collection of MediaSocket objects which describe the output data of the Blocks.