Om  1.0.0
A universal framework for multimedia simulation
Public Member Functions | Static Public Member Functions | List of all members
om::sound::resources::SoundBufferResourceTranscoder Class Reference

A class that encodes and decodes sound buffers to/from the resource set format. More...

#include <omSoundBufferResourceTranscoder.h>

Inheritance diagram for om::sound::resources::SoundBufferResourceTranscoder:
om::resources::ResourceSetTypeTranscoder< SoundBuffer >

Public Member Functions

virtual Bool encode (const ResourceID &resourceID, const SoundBuffer &buffer, const ResourceSet &resources, ResourceEncoder &encoder, ResourceManager *resourceManager=((void *) 0))
 Encode an object of this resource type into a binary format. More...
 
virtual SoundBufferdecode (ResourceID &resourceID, ResourceDecoder &decoder, ResourceReferencePatcher &references, ResourceManager *resourceManager=((void *) 0))
 Decode an object of the resource type, constructing and returning a pointer to the final object. More...
 
- Public Member Functions inherited from om::resources::ResourceSetTypeTranscoder< SoundBuffer >
virtual ~ResourceSetTypeTranscoder ()
 Destroy the resource type transcoder, releasing internal resources. More...
 
const ResourceTypegetResourceType () const
 Return the resource type for the data type that this resource type handles. More...
 
virtual Bool encode (const ResourceID &resourceID, const SoundBuffer &data, const ResourceSet &resources, ResourceEncoder &encoder, ResourceManager *resourceManager=((void *) 0))=0
 Encode an object of this resource type into a binary format. More...
 
virtual void patchReferences (const ResourceReference *references, Size numReferences, const ResourceSet &resources, SoundBuffer &data)
 Patch the specified array of references for a previously-decoded object from the given set of resources. More...
 
virtual void finalize (SoundBuffer &data)
 Finish loading an object and perform final initialization after all references have been patched. More...
 
virtual SoundBuffer * instance (const SoundBuffer &data, const ResourceSetTranscoder &transcoder, ResourceSet &resources) const
 Duplicate an object from a prototype and return a pointer to the new object. More...
 
virtual void replaceInstances (SoundBuffer &data, const Prototype &prototype, const Prototype &instance, const ResourceSetTranscoder &transcoder, ResourceSet &resources) const
 Replace child object instances on a new prototype component. More...
 
virtual Bool findInstances (const SoundBuffer &data, const Prototype &prototype, const Prototype &instance, const ResourceSetTranscoder &transcoder) const
 Return whether or not any child objects were instanced by a prototype. More...
 

Static Public Member Functions

static void encode (const SoundBuffer &buffer, ResourceEncoder &encoder)
 Encode a sound buffer using the specified resource encoder. More...
 
static void decode (ResourceDecoder &decoder, SoundBuffer &buffer)
 Encode a sound buffer using the specified resource encoder. More...
 
static void encodeChannelLayout (const ChannelLayout &layout, ResourceEncoder &encoder)
 Encode a channel layout using the specified resource encoder. More...
 
static void decodeChannelLayout (ResourceDecoder &decoder, ChannelLayout &layout)
 Encode a channel layout using the specified resource encoder. More...
 

Additional Inherited Members

- Static Protected Member Functions inherited from om::resources::ResourceSetTypeTranscoder< SoundBuffer >
static InstanceType * replaceInstance (InstanceType *data, const Prototype &prototype, const Prototype &instance, const ResourceSetTranscoder &transcoder, ResourceSet &resources)
 
static OpaqueResource replaceInstance (const OpaqueResource &data, const Prototype &prototype, const Prototype &instance, const ResourceSetTranscoder &transcoder, ResourceSet &resources)
 
static void * replaceInstance (void *data, const ResourceType &dataType, const Prototype &prototype, const Prototype &instance, const ResourceSetTranscoder &transcoder, ResourceSet &resources)
 
static Bool findInstance (InstanceType *data, const Prototype &prototype, const Prototype &instance, const ResourceSetTranscoder &transcoder)
 
static Bool findInstance (const OpaqueResource &data, const Prototype &prototype, const Prototype &instance, const ResourceSetTranscoder &transcoder)
 
static Bool findInstance (void *data, const ResourceType &dataType, const Prototype &prototype, const Prototype &instance, const ResourceSetTranscoder &transcoder)
 

Detailed Description

A class that encodes and decodes sound buffers to/from the resource set format.

Member Function Documentation

virtual Bool om::sound::resources::SoundBufferResourceTranscoder::encode ( const ResourceID resourceID,
const SoundBuffer buffer,
const ResourceSet resources,
ResourceEncoder encoder,
ResourceManager resourceManager = ((void *) 0) 
)
virtual

Encode an object of this resource type into a binary format.

virtual SoundBuffer* om::sound::resources::SoundBufferResourceTranscoder::decode ( ResourceID resourceID,
ResourceDecoder decoder,
ResourceReferencePatcher references,
ResourceManager resourceManager = ((void *) 0) 
)
virtual

Decode an object of the resource type, constructing and returning a pointer to the final object.

Implements om::resources::ResourceSetTypeTranscoder< SoundBuffer >.

static void om::sound::resources::SoundBufferResourceTranscoder::encode ( const SoundBuffer buffer,
ResourceEncoder encoder 
)
static

Encode a sound buffer using the specified resource encoder.

static void om::sound::resources::SoundBufferResourceTranscoder::decode ( ResourceDecoder decoder,
SoundBuffer buffer 
)
static

Encode a sound buffer using the specified resource encoder.

static void om::sound::resources::SoundBufferResourceTranscoder::encodeChannelLayout ( const ChannelLayout layout,
ResourceEncoder encoder 
)
static

Encode a channel layout using the specified resource encoder.

static void om::sound::resources::SoundBufferResourceTranscoder::decodeChannelLayout ( ResourceDecoder decoder,
ChannelLayout layout 
)
static

Encode a channel layout using the specified resource encoder.


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