Theora Playback Library  1.0.0
All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | List of all members
TheoraMemoryFileDataSource Class Reference
Inheritance diagram for TheoraMemoryFileDataSource:
TheoraDataSource

Public Member Functions

 TheoraMemoryFileDataSource (std::string filename)
 
 ~TheoraMemoryFileDataSource ()
 
int read (void *output, int nBytes)
 
void seek (unsigned long byte_index)
 position the source pointer to byte_index from the start of the source More...
 
std::string repr ()
 returns a string representation of the DataSource, eg 'File: source.ogg' More...
 
unsigned long size ()
 return the size of the stream in bytes More...
 
unsigned long tell ()
 return the current position of the source pointer More...
 
std::string getFilename ()
 
- Public Member Functions inherited from TheoraDataSource
virtual ~TheoraDataSource ()
 

Detailed Description

Pre-loads the entire file and streams from memory. Very useful if you're continuously displaying a video and want to avoid disk reads. Not very practical for large files.

Constructor & Destructor Documentation

TheoraMemoryFileDataSource::TheoraMemoryFileDataSource ( std::string  filename)
TheoraMemoryFileDataSource::~TheoraMemoryFileDataSource ( )

Member Function Documentation

std::string TheoraMemoryFileDataSource::getFilename ( )
inline
int TheoraMemoryFileDataSource::read ( void *  output,
int  nBytes 
)
virtual

Reads nBytes bytes from data source and returns number of read bytes. if function returns less bytes then nBytes, the system assumes EOF is reached.

Implements TheoraDataSource.

std::string TheoraMemoryFileDataSource::repr ( )
inlinevirtual

returns a string representation of the DataSource, eg 'File: source.ogg'

Implements TheoraDataSource.

void TheoraMemoryFileDataSource::seek ( unsigned long  byte_index)
virtual

position the source pointer to byte_index from the start of the source

Implements TheoraDataSource.

unsigned long TheoraMemoryFileDataSource::size ( )
virtual

return the size of the stream in bytes

Implements TheoraDataSource.

unsigned long TheoraMemoryFileDataSource::tell ( )
virtual

return the current position of the source pointer

Implements TheoraDataSource.


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