org.ogre4j
Class Renderable

java.lang.Object
  extended by org.xbig.base.NativeObject
      extended by org.ogre4j.Renderable
All Implemented Interfaces:
IRenderable, INativeObject

public class Renderable
extends NativeObject
implements IRenderable


Nested Class Summary
protected static class Renderable.CustomParameterMap
           
static class Renderable.RenderSystemData
           
static class Renderable.Visitor
           
 
Nested classes/interfaces inherited from interface org.ogre4j.IRenderable
IRenderable.ICustomParameterMap, IRenderable.IRenderSystemData, IRenderable.IVisitor
 
Field Summary
 
Fields inherited from class org.xbig.base.NativeObject
deleted, object, remote
 
Constructor Summary
  Renderable(InstancePointer p)
          This constructor is public for internal useage only!
protected Renderable(InstancePointer p, boolean remote)
          Creates a Java wrapper object for an existing C++ object.
  Renderable(WithoutNativeObject val)
          Allows creation of Java objects without C++ objects.
 
Method Summary
 void _updateCustomGpuParameter(IGpuProgramParameters.IAutoConstantEntry constantEntry, IGpuProgramParameters params)
          Update a custom constant which is derived from information only this knows.
 void delete()
          Deletes the corresponding C++ object.
 void finalize()
           
 boolean getCastsShadows()
          Method which reports whether this renderable would normally cast a shadow.
 IVector4 getCustomParameter(int index)
          Gets the custom value associated with this at the given index.
 ILightList getLights()
          Gets a list of lights, ordered relative to how close they are to this renderable.
 IMaterialPtr getMaterial()
          Retrieves a weak reference to the material this renderable object uses.
 int getNumWorldTransforms()
          Returns the number of world transform matrices this renderable requires.
 boolean getPolygonModeOverrideable()
          Gets whether this renderable's chosen detail level can be overridden (downgraded) by the camera setting.
 void getRenderOperation(IRenderOperation op)
          Gets the render operation required to send this object to the frame buffer.
 IRenderable.IRenderSystemData getRenderSystemData()
          Sets render system private data
 float getSquaredViewDepth(ICamera cam)
          Returns the camera-relative squared depth of this renderable.
 ITechnique getTechnique()
          Retrieves a pointer to the this renderable object uses.
 boolean getUseIdentityProjection()
          Returns whether or not to use an 'identity' projection.
 boolean getUseIdentityView()
          Returns whether or not to use an 'identity' view.
 IAny getUserAny()
          Retrieves the custom user value associated with this object.
 void getWorldTransforms(IMatrix4 xform)
          Gets the world transform matrix / matrices for this renderable object.
 void postRender(ISceneManager sm, IRenderSystem rsys)
          Called immediately after the has been rendered.
 boolean preRender(ISceneManager sm, IRenderSystem rsys)
          Called just prior to the being rendered.
 void setCustomParameter(int index, IVector4 value)
          Sets a custom parameter for this , which may be used to drive calculations for this specific , like GPU program parameters.
 void setPolygonModeOverrideable(boolean override)
          Sets whether this renderable's chosen detail level can be overridden (downgraded) by the camera setting.
 void setRenderSystemData(IRenderable.IRenderSystemData val)
          gets render system private data
 void setUseIdentityProjection(boolean useIdentityProjection)
          Sets whether or not to use an 'identity' projection.
 void setUseIdentityView(boolean useIdentityView)
          Sets whether or not to use an 'identity' view.
 void setUserAny(IAny anything)
          Sets any kind of user value on this object.
 
Methods inherited from class org.xbig.base.NativeObject
disconnectFromNativeObject, equals, getInstancePointer, hashCode, setInstancePointer, setInstancePointer, setInstancePointer, toString
 
Methods inherited from class java.lang.Object
clone, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.xbig.base.INativeObject
disconnectFromNativeObject, getInstancePointer, setInstancePointer, setInstancePointer, setInstancePointer
 

Constructor Detail

Renderable

public Renderable(InstancePointer p)
This constructor is public for internal useage only! Do not use it!


Renderable

protected Renderable(InstancePointer p,
                     boolean remote)
Creates a Java wrapper object for an existing C++ object. If remote is set to 'true' this object cannot be deleted in Java.


Renderable

public Renderable(WithoutNativeObject val)
Allows creation of Java objects without C++ objects.

See Also:
WithoutNativeObject, INativeObject.disconnectFromNativeObject()
Method Detail

delete

public void delete()
Description copied from interface: INativeObject
Deletes the corresponding C++ object.

Subclasses must implement this but if the native instance was created by the underlying library the native call to dispose must not happen!

Specified by:
delete in interface INativeObject
Specified by:
delete in class NativeObject
See Also:
#remote

finalize

public void finalize()
Overrides:
finalize in class NativeObject

getMaterial

public IMaterialPtr getMaterial()
Retrieves a weak reference to the material this renderable object uses.

Specified by:
getMaterial in interface IRenderable

getTechnique

public ITechnique getTechnique()
Retrieves a pointer to the this renderable object uses.

Specified by:
getTechnique in interface IRenderable

getRenderOperation

public void getRenderOperation(IRenderOperation op)
Gets the render operation required to send this object to the frame buffer.

Specified by:
getRenderOperation in interface IRenderable

preRender

public boolean preRender(ISceneManager sm,
                         IRenderSystem rsys)
Called just prior to the being rendered.

Specified by:
preRender in interface IRenderable

postRender

public void postRender(ISceneManager sm,
                       IRenderSystem rsys)
Called immediately after the has been rendered.

Specified by:
postRender in interface IRenderable

getWorldTransforms

public void getWorldTransforms(IMatrix4 xform)
Gets the world transform matrix / matrices for this renderable object.

Specified by:
getWorldTransforms in interface IRenderable

getNumWorldTransforms

public int getNumWorldTransforms()
Returns the number of world transform matrices this renderable requires.

Specified by:
getNumWorldTransforms in interface IRenderable

setUseIdentityProjection

public void setUseIdentityProjection(boolean useIdentityProjection)
Sets whether or not to use an 'identity' projection.

Specified by:
setUseIdentityProjection in interface IRenderable

getUseIdentityProjection

public boolean getUseIdentityProjection()
Returns whether or not to use an 'identity' projection.

Specified by:
getUseIdentityProjection in interface IRenderable

setUseIdentityView

public void setUseIdentityView(boolean useIdentityView)
Sets whether or not to use an 'identity' view.

Specified by:
setUseIdentityView in interface IRenderable

getUseIdentityView

public boolean getUseIdentityView()
Returns whether or not to use an 'identity' view.

Specified by:
getUseIdentityView in interface IRenderable

getSquaredViewDepth

public float getSquaredViewDepth(ICamera cam)
Returns the camera-relative squared depth of this renderable.

Specified by:
getSquaredViewDepth in interface IRenderable

getLights

public ILightList getLights()
Gets a list of lights, ordered relative to how close they are to this renderable.

Specified by:
getLights in interface IRenderable

getCastsShadows

public boolean getCastsShadows()
Method which reports whether this renderable would normally cast a shadow.

Specified by:
getCastsShadows in interface IRenderable

setCustomParameter

public void setCustomParameter(int index,
                               IVector4 value)
Sets a custom parameter for this , which may be used to drive calculations for this specific , like GPU program parameters.

Specified by:
setCustomParameter in interface IRenderable

getCustomParameter

public IVector4 getCustomParameter(int index)
Gets the custom value associated with this at the given index.

Specified by:
getCustomParameter in interface IRenderable

_updateCustomGpuParameter

public void _updateCustomGpuParameter(IGpuProgramParameters.IAutoConstantEntry constantEntry,
                                      IGpuProgramParameters params)
Update a custom constant which is derived from information only this knows.

Specified by:
_updateCustomGpuParameter in interface IRenderable

setPolygonModeOverrideable

public void setPolygonModeOverrideable(boolean override)
Sets whether this renderable's chosen detail level can be overridden (downgraded) by the camera setting.

Specified by:
setPolygonModeOverrideable in interface IRenderable

getPolygonModeOverrideable

public boolean getPolygonModeOverrideable()
Gets whether this renderable's chosen detail level can be overridden (downgraded) by the camera setting.

Specified by:
getPolygonModeOverrideable in interface IRenderable

setUserAny

public void setUserAny(IAny anything)
Sets any kind of user value on this object.

Specified by:
setUserAny in interface IRenderable

getUserAny

public IAny getUserAny()
Retrieves the custom user value associated with this object.

Specified by:
getUserAny in interface IRenderable

getRenderSystemData

public IRenderable.IRenderSystemData getRenderSystemData()
Sets render system private data

Specified by:
getRenderSystemData in interface IRenderable

setRenderSystemData

public void setRenderSystemData(IRenderable.IRenderSystemData val)
gets render system private data

Specified by:
setRenderSystemData in interface IRenderable


Copyright © 2007 netAllied GmbH. All Rights Reserved.