FileDocCategorySizeDatePackage
NativeDecoder.javaAPI DocJMF 2.1.1e2130Mon May 12 12:21:02 BST 2003com.ibm.media.codec.audio.g723

NativeDecoder

public class NativeDecoder extends JavaDecoder

Fields Summary
int
nativeData
Constructors Summary
public NativeDecoder()

    
Methods Summary
public voidclose()
Clean up

        freeNative();
    
protected voiddecode(byte[] inpData, int readPtr, byte[] outData, int writePtr, int inpLength)


        decodeNative(inpData,readPtr,outData,writePtr,inpLength);
    
private native booleandecodeNative(byte[] inpBuffer, int readPtr, byte[] outBuffer, int writePtr, int inpLength)

private native voidfreeNative()

private native voidinitNative()

public voidopen()
Initializes the codec.

    	try {
            com.sun.media.JMFSecurityManager.loadLibrary("jmutil");
            com.sun.media.JMFSecurityManager.loadLibrary("jmg723");
            initNative();
            return;

        } catch (Throwable t) {
            System.err.println("can not load "+PLUGIN_NAME);
            System.err.println("reason : "+t);
            throw new ResourceUnavailableException("can not load "+PLUGIN_NAME);

	}

    
public voidreset()

        resetNative();
    
private native voidresetNative()