CrystalSpace

Public API Reference

CS::Media::iMediaContainer Struct Reference

Container for the different streams inside a video file. More...

#include <ivideo/videodecode.h>

Inheritance diagram for CS::Media::iMediaContainer:

List of all members.

Public Member Functions

Public methods



virtual void AddLanguage (const MediaLanguage &language)=0
 Add a new external audio language stream.
virtual const char * GetDescription () const =0
 Get a textual description of the media container.
virtual const MediaLanguageGetLanguage (size_t index) const =0
 Get the language at the given index.
virtual size_t GetLanguageCount () const =0
 Get the number of languages in the container.
virtual iMediaGetMedia (size_t index)=0
 Get an iMedia object specified by its index.
virtual size_t GetMediaCount () const =0
 Return the number of iMedia objects inside the container.
Methods internal to the iMediaPlayer



virtual void AutoActivateStreams ()=0
 Automatically activate the first stream of every kind from inside the container.
virtual void DropFrame ()=0
 Trigger a frame drop.
virtual bool Eof () const =0
 Check if the end of file has been reached.
virtual float GetAspectRatio ()=0
 Get the aspect ratio associated to the active video stream.
virtual float GetDuration () const =0
 Get the length of the media in seconds.
virtual float GetPosition () const =0
 Get the position of the media in seconds.
virtual iSndSysStreamGetTargetAudio ()=0
 Get a reference to the internal audio stream.
virtual iTextureHandleGetTargetTexture ()=0
 Get a reference to the internal texture buffer.
virtual void OnPause ()=0
 Callback for the "Pause" command.
virtual void OnPlay ()=0
 Callback for the "Play" command.
virtual void OnStop ()=0
 Callback for the "Stop" command.
virtual bool RemoveActiveStream (size_t index)=0
 Deactivate a stream.
virtual void SetActiveStream (size_t index)=0
 Activate a stream.
virtual void SetCacheSize (size_t size)=0
 Set the number of frames to be cached.
virtual void SetCurrentLanguage (const char *identifier)=0
 Set the current language to be played.
virtual void SetPosition (float time)=0
 Trigger a seek for the active iMedia streams, resolved at the next update.
virtual void SwapBuffers ()=0
 Swap the active buffer for the last one that was written to inside the active iMedia.
virtual void Update ()=0
 Update the active streams.
virtual void WriteData ()=0
 Get data from the prefetching queue and write it to the active buffer.

Detailed Description

Container for the different streams inside a video file.

Most of the methods of this object are not intended to be used directly by the user, but by the iMediaPlayer instead.

Definition at line 106 of file videodecode.h.


Member Function Documentation

virtual void CS::Media::iMediaContainer::AddLanguage ( const MediaLanguage language  )  [pure virtual]

Add a new external audio language stream.

virtual void CS::Media::iMediaContainer::AutoActivateStreams (  )  [pure virtual]

Automatically activate the first stream of every kind from inside the container.

virtual void CS::Media::iMediaContainer::DropFrame (  )  [pure virtual]

Trigger a frame drop.

virtual bool CS::Media::iMediaContainer::Eof (  )  const [pure virtual]

Check if the end of file has been reached.

virtual float CS::Media::iMediaContainer::GetAspectRatio (  )  [pure virtual]

Get the aspect ratio associated to the active video stream.

virtual const char* CS::Media::iMediaContainer::GetDescription (  )  const [pure virtual]

Get a textual description of the media container.

virtual float CS::Media::iMediaContainer::GetDuration (  )  const [pure virtual]

Get the length of the media in seconds.

virtual const MediaLanguage& CS::Media::iMediaContainer::GetLanguage ( size_t  index  )  const [pure virtual]

Get the language at the given index.

Parameters:
index Index of the language, defined in the interval [0,GetLanguageCount ()-1]
virtual size_t CS::Media::iMediaContainer::GetLanguageCount (  )  const [pure virtual]

Get the number of languages in the container.

virtual iMedia* CS::Media::iMediaContainer::GetMedia ( size_t  index  )  [pure virtual]

Get an iMedia object specified by its index.

Parameters:
index Index of a media stream
virtual size_t CS::Media::iMediaContainer::GetMediaCount (  )  const [pure virtual]

Return the number of iMedia objects inside the container.

virtual float CS::Media::iMediaContainer::GetPosition (  )  const [pure virtual]

Get the position of the media in seconds.

virtual iSndSysStream* CS::Media::iMediaContainer::GetTargetAudio (  )  [pure virtual]

Get a reference to the internal audio stream.

Returns:
the target audio stream
virtual iTextureHandle* CS::Media::iMediaContainer::GetTargetTexture (  )  [pure virtual]

Get a reference to the internal texture buffer.

Returns:
the target texture
virtual void CS::Media::iMediaContainer::OnPause (  )  [pure virtual]

Callback for the "Pause" command.

virtual void CS::Media::iMediaContainer::OnPlay (  )  [pure virtual]

Callback for the "Play" command.

virtual void CS::Media::iMediaContainer::OnStop (  )  [pure virtual]

Callback for the "Stop" command.

virtual bool CS::Media::iMediaContainer::RemoveActiveStream ( size_t  index  )  [pure virtual]

Deactivate a stream.

Parameters:
index Index of an active media stream
virtual void CS::Media::iMediaContainer::SetActiveStream ( size_t  index  )  [pure virtual]

Activate a stream.

In case there's already an activated stream of that type, it is replaced.

Parameters:
index Index of a media stream
virtual void CS::Media::iMediaContainer::SetCacheSize ( size_t  size  )  [pure virtual]

Set the number of frames to be cached.

virtual void CS::Media::iMediaContainer::SetCurrentLanguage ( const char *  identifier  )  [pure virtual]

Set the current language to be played.

Parameters:
identifier The name of the target language
virtual void CS::Media::iMediaContainer::SetPosition ( float  time  )  [pure virtual]

Trigger a seek for the active iMedia streams, resolved at the next update.

virtual void CS::Media::iMediaContainer::SwapBuffers (  )  [pure virtual]

Swap the active buffer for the last one that was written to inside the active iMedia.

virtual void CS::Media::iMediaContainer::Update (  )  [pure virtual]

Update the active streams.

virtual void CS::Media::iMediaContainer::WriteData (  )  [pure virtual]

Get data from the prefetching queue and write it to the active buffer.


The documentation for this struct was generated from the following file:

Generated for Crystal Space 2.1 by doxygen 1.6.1