org.jouvieje.fmodex.structures
Class FMOD_CODEC_STATE

java.lang.Object
  extended byorg.jouvieje.fmodex.utils.Pointer
      extended byorg.jouvieje.fmodex.structures.FMOD_CODEC_STATE

public class FMOD_CODEC_STATE
extends Pointer


Constructor Summary
FMOD_CODEC_STATE()
          Create an object that holds a null FMOD_CODEC_STATE.
 
Method Summary
static FMOD_CODEC_STATE allocate()
          Allocate a new FMOD_CODEC_STATE.
static FMOD_CODEC_STATE asFMOD_CODEC_STATE(Pointer pointer)
          Create a view of the Pointer object as a FMOD_CODEC_STATE object.
 Pointer getFileHandle()
          [out] This will return an internal FMOD file handle to use with the callbacks provided.
 int getFileSize()
          [out] This will contain the size of the file in bytes.
 int getNumSubsounds()
          [in] Number of 'subsounds' in this sound.
 Pointer getPluginData()
          [in] Plugin writer created data the codec author wants to attach to this object.
 FMOD_CODEC_WAVEFORMAT getWaveFormat()
          [in] Pointer to an array of format structures containing information about each sample.
 FMOD_RESULT invokeFileRead(Pointer handle, java.nio.ByteBuffer buffer, int sizebytes, java.nio.IntBuffer bytesread, Pointer userdata)
          Invoke an internal FMOD callback.
 FMOD_RESULT invokeFileSeek(Pointer handle, int pos, Pointer userdata)
          Invoke an internal FMOD callback.
 FMOD_RESULT invokeMetadata(FMOD_CODEC_STATE codec_state, FMOD_TAGTYPE tagtype, java.lang.String name, Pointer data, int datalen, FMOD_TAGDATATYPE datatype, int unique)
          Invoke an internal FMOD callback.
 void release()
           
 void setNumSubsounds(int numSubsounds)
          [in] Number of 'subsounds' in this sound.
 void setPluginData(Pointer pluginData)
          [in] Plugin writer created data the codec author wants to attach to this object.
 void setWaveFormat(FMOD_CODEC_WAVEFORMAT waveFormat)
          [in] Pointer to an array of format structures containing information about each sample.
 
Methods inherited from class org.jouvieje.fmodex.utils.Pointer
asByteBuffer, asDouble, asFloat, asInt, asLong, asPointer, asString, asString, equals, isNull, shareMemory
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FMOD_CODEC_STATE

public FMOD_CODEC_STATE()
Create an object that holds a null FMOD_CODEC_STATE.
The call isNull() on the object created will returns true.
  FMOD_CODEC_STATE obj = new FMOD_CODEC_STATE();
  (obj == null) <=> false
  obj.isNull() <=> true
 
To creates a new FMOD_CODEC_STATE, use the static "constructor" :
  FMOD_CODEC_STATE obj = FMOD_CODEC_STATE.allocate();

See Also:
allocate()
Method Detail

asFMOD_CODEC_STATE

public static FMOD_CODEC_STATE asFMOD_CODEC_STATE(Pointer pointer)
Create a view of the Pointer object as a FMOD_CODEC_STATE object.
This view is valid only if the memory holded by the Pointer holds a FMOD_CODEC_STATE object.


allocate

public static FMOD_CODEC_STATE allocate()
Allocate a new FMOD_CODEC_STATE.
The call isNull() on the object created will return false.
  FMOD_CODEC_STATE obj = FMOD_CODEC_STATE.allocate();
  (obj == null) <=> obj.isNull() <=> false
 


release

public void release()

getNumSubsounds

public int getNumSubsounds()
[in] Number of 'subsounds' in this sound. Anything other than 0 makes it a 'container' format (ie CDDA/DLS/FSB etc which contain 1 or more su bsounds). For most normal, single sound codec such as WAV/AIFF/MP3, this should be 0 as they are not a container for subsounds, they are the sound by itself.


setNumSubsounds

public void setNumSubsounds(int numSubsounds)
[in] Number of 'subsounds' in this sound. Anything other than 0 makes it a 'container' format (ie CDDA/DLS/FSB etc which contain 1 or more su bsounds). For most normal, single sound codec such as WAV/AIFF/MP3, this should be 0 as they are not a container for subsounds, they are the sound by itself.


getWaveFormat

public FMOD_CODEC_WAVEFORMAT getWaveFormat()
[in] Pointer to an array of format structures containing information about each sample. Can be 0 or NULL if FMOD_CODEC_GETWAVEFORMAT callback is preferred. The number of entries here must equal the number of subsounds defined in the subsound parameter. If numsubsounds = 0 then there should be 1 instance of this structure.


setWaveFormat

public void setWaveFormat(FMOD_CODEC_WAVEFORMAT waveFormat)
[in] Pointer to an array of format structures containing information about each sample. Can be 0 or NULL if FMOD_CODEC_GETWAVEFORMAT callback is preferred. The number of entries here must equal the number of subsounds defined in the subsound parameter. If numsubsounds = 0 then there should be 1 instance of this structure.


getPluginData

public Pointer getPluginData()
[in] Plugin writer created data the codec author wants to attach to this object.


setPluginData

public void setPluginData(Pointer pluginData)
[in] Plugin writer created data the codec author wants to attach to this object.


getFileHandle

public Pointer getFileHandle()
[out] This will return an internal FMOD file handle to use with the callbacks provided.


getFileSize

public int getFileSize()
[out] This will contain the size of the file in bytes.


invokeFileRead

public FMOD_RESULT invokeFileRead(Pointer handle,
                                  java.nio.ByteBuffer buffer,
                                  int sizebytes,
                                  java.nio.IntBuffer bytesread,
                                  Pointer userdata)
Invoke an internal FMOD callback.
Don't use this for user callbacks (callback created from Java).

For an example of its use, look at CodecRaw esxample.


invokeFileSeek

public FMOD_RESULT invokeFileSeek(Pointer handle,
                                  int pos,
                                  Pointer userdata)
Invoke an internal FMOD callback.
Don't use this for user callbacks (callback created from Java).

For an example of its use, look at CodecRaw esxample.


invokeMetadata

public FMOD_RESULT invokeMetadata(FMOD_CODEC_STATE codec_state,
                                  FMOD_TAGTYPE tagtype,
                                  java.lang.String name,
                                  Pointer data,
                                  int datalen,
                                  FMOD_TAGDATATYPE datatype,
                                  int unique)
Invoke an internal FMOD callback.
Don't use this for user callbacks (callback created from Java).

For an example of its use, look at CodecRaw esxample.



NativeFmodEx Project - © Copyright 2005-2010 - Jérôme Jouvie (Jouvieje)
NativeFmodEx is an Open Source Project under GNU LGPL License
My sites : http://jerome.jouvie.free.fr/

(Documentation Copyright © Firelight Technologies - FMOD Ex - http://www.fmod.org)