com.visioglobe.libVisioDevKit
Class VgITextureManager

java.lang.Object
  extended by com.visioglobe.libVisioDevKit.VgITextureManager

public class VgITextureManager
extends java.lang.Object

The VgITextureManager class is used to create VgITexture given a VgBinaryBuffer. The VgITextureManager class is in charge of passing the VgBinaryBuffer data to the graphics engine and creates internal objects that allows usage of the returned texture. The below code snippet demonstrates how a VgITexture can be created.

Interface:
VgEngine::VgITextureManager
Date:
25/02/2010

Field Summary
protected  boolean swigCMemOwn
           
 
Constructor Summary
VgITextureManager(long cPtr, boolean cMemoryOwn)
           
 
Method Summary
 VgITextureRefPtr createTexture(VgBinaryBufferConstRefPtr pBuffer)
           
 VgITextureRefPtr createTexture(VgBinaryBufferConstRefPtr pBuffer, boolean pGenerateMipmaps)
          Creates a Texture from a VgBinaryBuffer.
 void delete()
           
protected  void finalize()
           
static long getCPtr(VgITextureManager obj)
           
static VgBinaryBufferRefPtr prepareTextureBuffer(long pWidth, long pHeight, VgPixelFormat pPixelFormat, SWIGTYPE_p_p_unsigned_char pOutData)
           
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

swigCMemOwn

protected boolean swigCMemOwn
Constructor Detail

VgITextureManager

public VgITextureManager(long cPtr,
                         boolean cMemoryOwn)
Method Detail

getCPtr

public static long getCPtr(VgITextureManager obj)

finalize

protected void finalize()
Overrides:
finalize in class java.lang.Object

delete

public void delete()

createTexture

public VgITextureRefPtr createTexture(VgBinaryBufferConstRefPtr pBuffer,
                                      boolean pGenerateMipmaps)
Creates a Texture from a VgBinaryBuffer.

Parameters:
pBuffer - The buffer from where the texture will be loaded.
pGenerateMipmaps - Indicates whether mipmaps should be auto-generated.
Remark:
Once the VgBinaryBuffer is used to create a VgITexture, it should not be modified afterwards. The graphic's context should be active when this call is made., Under iOS, if the VgBinaryBuffer contains a png file. It must not be compressed (Uncheck "Compress PNG Files" under XCode), and the internal png reader does not handle Apple proprietary png extensions.

createTexture

public VgITextureRefPtr createTexture(VgBinaryBufferConstRefPtr pBuffer)

prepareTextureBuffer

public static VgBinaryBufferRefPtr prepareTextureBuffer(long pWidth,
                                                        long pHeight,
                                                        VgPixelFormat pPixelFormat,
                                                        SWIGTYPE_p_p_unsigned_char pOutData)

VisioDevKit 2.0, Visioglobe® 2013