|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.xith3d.scenegraph.SceneGraphObject
org.xith3d.scenegraph.Node
org.xith3d.scenegraph.Leaf
org.xith3d.scenegraph.Shape3D
org.xith3d.scenegraph.primitives.Quad
public class Quad
This is a simple, single textured quad implementation.
A Quad is a four-edged polygon, that doesn't necessarily need to be
rectangular.
If you just want a rectangular Quad you should consider to use Rectangle
instad of Quad.
| Field Summary |
|---|
| Fields inherited from class org.xith3d.scenegraph.Node |
|---|
bounds, boundsAutoCompute, boundsDirty, globalIgnoreBounds, instanceBoundsTypeHint, transformGroup, untransformedBounds |
| Fields inherited from class org.xith3d.scenegraph.SceneGraphObject |
|---|
XITH3D_USERDATAKEY_OLDUSERDATA |
| Constructor Summary | |
|---|---|
Quad(org.openmali.vecmath2.Point3f[] coords)
Creates an untextured Quad without alpha channel. |
|
Quad(org.openmali.vecmath2.Point3f[] coords,
boolean generateNormals)
Creates an untextured Quad without alpha channel. |
|
Quad(org.openmali.vecmath2.Point3f[] coords,
boolean generateNormals,
org.openmali.vecmath2.Colorf color)
Creates an untextured, but colored Quad. |
|
Quad(org.openmali.vecmath2.Point3f[] coords,
boolean generateNormals,
java.lang.String texture)
Creates a textured Quad. |
|
Quad(org.openmali.vecmath2.Point3f[] coords,
boolean generateNormals,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
java.lang.String texture)
Creates a textured Quad. |
|
Quad(org.openmali.vecmath2.Point3f[] coords,
boolean generateNormals,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
java.lang.String texture,
org.openmali.vecmath2.Colorf color)
Creates a textured Quad. |
|
Quad(org.openmali.vecmath2.Point3f[] coords,
boolean generateNormals,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
Texture texture)
Creates a textured Quad. |
|
Quad(org.openmali.vecmath2.Point3f[] coords,
boolean generateNormals,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
Texture texture,
org.openmali.vecmath2.Colorf color)
Creates a textured Quad. |
|
Quad(org.openmali.vecmath2.Point3f[] coords,
org.openmali.vecmath2.Colorf color)
Creates an untextured, but colored Quad. |
|
Quad(org.openmali.vecmath2.Point3f[] coords,
java.lang.String texture)
Creates a textured Quad. |
|
Quad(org.openmali.vecmath2.Point3f[] coords,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
java.lang.String texture)
Creates a textured Quad. |
|
Quad(org.openmali.vecmath2.Point3f[] coords,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
java.lang.String texture,
org.openmali.vecmath2.Colorf color)
Creates a textured Quad. |
|
Quad(org.openmali.vecmath2.Point3f[] coords,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
Texture texture)
Creates a textured Quad. |
|
Quad(org.openmali.vecmath2.Point3f[] coords,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
Texture texture,
org.openmali.vecmath2.Colorf color)
Creates a textured Quad. |
|
Quad(org.openmali.vecmath2.Point3f[] coords,
Texture texture)
Creates a textured Quad. |
|
Quad(java.lang.String texture,
org.openmali.vecmath2.Tuple3f[] vertices,
org.openmali.vecmath2.TexCoord2f[] textureCoords)
Deprecated. |
|
Quad(org.openmali.vecmath2.Tuple3f[] vertices)
Deprecated. |
|
Quad(org.openmali.vecmath2.Tuple3f[] vertices,
org.openmali.vecmath2.Colorf color)
Deprecated. |
|
Quad(org.openmali.vecmath2.Tuple3f[] vertices,
java.lang.String texture)
Deprecated. |
|
Quad(org.openmali.vecmath2.Tuple3f[] vertices,
java.lang.String texture,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
org.openmali.vecmath2.Colorf color)
Deprecated. |
|
Quad(org.openmali.vecmath2.Tuple3f[] vertices,
Texture texture,
org.openmali.vecmath2.TexCoord2f[] textureCoords)
Deprecated. |
|
Quad(org.openmali.vecmath2.Tuple3f[] vertices,
Texture texture,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
org.openmali.vecmath2.Colorf color)
Deprecated. |
|
| Method Summary | |
|---|---|
protected TriangleFanArray |
createGeometry()
|
protected void |
generateNormals(Geometry geom)
|
float |
getAlpha()
|
org.openmali.vecmath2.Colorf |
getColor()
|
TriangleFanArray |
getGeometry()
|
Texture |
getTexture()
|
void |
setAlpha(float alpha)
Sets this Quad's alpha value. (-1f if not TransparencyAttributes are set.) |
void |
setColor(org.openmali.vecmath2.Colorf color)
Sets this Quad's color. |
void |
setTexture(java.lang.String texture)
Sets the new Texture for this Quad. |
void |
setTexture(java.lang.String texture,
org.openmali.vecmath2.TexCoord2f[] textureCoordinates)
Sets the new Texture together with texture-coordinates for this Quad. |
void |
setTexture(Texture texture)
Sets the new Texture for this Quad. |
void |
setTexture(Texture texture,
org.openmali.vecmath2.TexCoord2f[] textureCoordinates)
Sets the new Texture together with texture-coordinates for this Quad. |
void |
setTextureCoordinates(org.openmali.vecmath2.TexCoord2f[] textureCoordinates)
Sets the new texture-coordinates for this Quad. |
void |
setTexturePosition(org.openmali.vecmath2.TexCoord2f[] textureCoordinates)
Deprecated. please use setTextureCoordinates(TexCoord2f[]) instead. |
void |
setVertexCoords(org.openmali.vecmath2.Tuple3f[] coords)
Updates the vertex-coord-data of this Quad. |
void |
setVertexCoords(org.openmali.vecmath2.Tuple3f[] coords,
Geometry geom)
|
void |
setVertexCoords(org.openmali.vecmath2.Tuple3f ll,
org.openmali.vecmath2.Tuple3f lr,
org.openmali.vecmath2.Tuple3f ur,
org.openmali.vecmath2.Tuple3f ul)
Updates the vertex-coord-data of this Quad. |
void |
update(org.openmali.vecmath2.Tuple3f[] vertices)
Deprecated. please use setVertexCoords(Tuple3f[]), which abstracts the internal vertex order. |
void |
update(org.openmali.vecmath2.Tuple3f ll,
org.openmali.vecmath2.Tuple3f lr,
org.openmali.vecmath2.Tuple3f ul,
org.openmali.vecmath2.Tuple3f ur)
Deprecated. please use setVertexCoords(Tuple3f, Tuple3f, Tuple3f, Tuple3f), which abstracts the internal vertex order. |
| Methods inherited from class org.xith3d.scenegraph.Shape3D |
|---|
absorbDetails, copy, freeOpenGLResources, getAppearance, getAppearance, getCustomComparable, isBumpMappingEnabled, isShadowReceiver, isVisible, newAppearance, newInstance, setAppearance, setBounds, setBumpMappingEnabled, setBumpMappingEnabled, setCustomComparable, setGeometry, setIsShadowReceiver, setModListener, setVisible, sharedCopy, sharedCopy, traverse, updateBounds, updateBoundsCheap, updateWorldTransform, verifyAppChange |
| Methods inherited from class org.xith3d.scenegraph.Leaf |
|---|
dump, getPickHost, setPickHost |
| Methods inherited from class org.xith3d.scenegraph.SceneGraphObject |
|---|
getName, getUserData, getUserData, getUserDataMap, isLive, setLive, setName, setUserData, setUserData, setUserDataRecursive, setUserDataRecursive, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public Quad(org.openmali.vecmath2.Point3f[] coords,
boolean generateNormals,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
Texture texture,
org.openmali.vecmath2.Colorf color)
coords - the vertex-coords of the Quad (ll, lr, ur, ul)generateNormals - textureCoords - the texture coordinates for the Quad (ll, lr, ur, ul)texture - the texturecolor - the color for the ColoringAttributes
public Quad(org.openmali.vecmath2.Point3f[] coords,
boolean generateNormals,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
java.lang.String texture,
org.openmali.vecmath2.Colorf color)
coords - the vertex-coords of the Quad (ll, lr, ur, ul)generateNormals - textureCoords - the texture coordinates for the Quad (ll, lr, ur, ul)texture - the name of the texture (loaded with the TextureLoader)color - the color for the ColoringAttributes
public Quad(org.openmali.vecmath2.Point3f[] coords,
boolean generateNormals,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
Texture texture)
coords - the vertex-coords of the Quad (ll, lr, ur, ul)generateNormals - textureCoords - the texture coordinates for the Quad (ll, lr, ur, ul)texture - the name of the texture (loaded with the TextureLoader)
public Quad(org.openmali.vecmath2.Point3f[] coords,
boolean generateNormals,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
java.lang.String texture)
coords - the vertex-coords of the Quad (ll, lr, ur, ul)generateNormals - texture - the name of the texture (loaded with the TextureLoader)textureCoords - the texture coordinates for the Quad (ll, lr, ur, ul)
public Quad(org.openmali.vecmath2.Point3f[] coords,
boolean generateNormals,
org.openmali.vecmath2.Colorf color)
coords - the vertex-coords of the Quad (ll, lr, ur, ul)generateNormals - color - the color to use for coloring this Quad
public Quad(org.openmali.vecmath2.Point3f[] coords,
boolean generateNormals,
java.lang.String texture)
coords - the vertex-coords of the Quad (ll, lr, ur, ul)generateNormals - texture - the name of the texture (loaded with the TextureLoader)
public Quad(org.openmali.vecmath2.Point3f[] coords,
boolean generateNormals)
coords - the vertex-coords of the Quad (ll, lr, ur, ul)generateNormals -
public Quad(org.openmali.vecmath2.Point3f[] coords,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
Texture texture,
org.openmali.vecmath2.Colorf color)
coords - the vertex-coords of the Quad (ll, lr, ur, ul)textureCoords - the texture coordinates for the Quad (ll, lr, ur, ul)texture - the texturecolor - the color for the ColoringAttributes
public Quad(org.openmali.vecmath2.Point3f[] coords,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
java.lang.String texture,
org.openmali.vecmath2.Colorf color)
coords - the vertex-coords of the Quad (ll, lr, ur, ul)textureCoords - the texture coordinates for the Quad (ll, lr, ur, ul)texture - the name of the texture (loaded with the TextureLoader)color - the color for the ColoringAttributes
public Quad(org.openmali.vecmath2.Point3f[] coords,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
Texture texture)
coords - the vertex-coords of the Quad (ll, lr, ur, ul)textureCoords - the texture coordinates for the Quad (ll, lr, ur, ul)texture - the name of the texture (loaded with the TextureLoader)
public Quad(org.openmali.vecmath2.Point3f[] coords,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
java.lang.String texture)
coords - the vertex-coords of the Quad (ll, lr, ur, ul)textureCoords - the texture coordinates for the Quad (ll, lr, ur, ul)texture - the name of the texture (loaded with the TextureLoader)
public Quad(org.openmali.vecmath2.Point3f[] coords,
org.openmali.vecmath2.Colorf color)
coords - the vertex-coords of the Quad (ll, lr, ur, ul)color - the color to use for coloring this Quad
public Quad(org.openmali.vecmath2.Point3f[] coords,
Texture texture)
coords - the vertex-coords of the Quad (ll, lr, ur, ul)texture - the texture
public Quad(org.openmali.vecmath2.Point3f[] coords,
java.lang.String texture)
coords - the vertex-coords of the Quad (ll, lr, ur, ul)texture - the name of the texture (loaded with the TextureLoader)public Quad(org.openmali.vecmath2.Point3f[] coords)
coords - the vertex-coords of the Quad (ll, lr, ur, ul)
@Deprecated
public Quad(org.openmali.vecmath2.Tuple3f[] vertices,
Texture texture,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
org.openmali.vecmath2.Colorf color)
vertices - the vertices of the Quadtexture - the texturetextureCoords - the texture coordinates for the Quad (ll, lr, ul, ur)color - the color for the ColoringAttributes
@Deprecated
public Quad(org.openmali.vecmath2.Tuple3f[] vertices,
java.lang.String texture,
org.openmali.vecmath2.TexCoord2f[] textureCoords,
org.openmali.vecmath2.Colorf color)
vertices - the vertices of the Quadtexture - the name of the texture (loaded with the TextureLoader)textureCoords - the texture coordinates for the Quad (ll, lr, ul, ur)color - the color for the ColoringAttributes
@Deprecated
public Quad(org.openmali.vecmath2.Tuple3f[] vertices,
Texture texture,
org.openmali.vecmath2.TexCoord2f[] textureCoords)
vertices - the vertices of the Quadtexture - the name of the texture (loaded with the TextureLoader)textureCoords - the texture coordinates for the Quad (ll, lr, ul, ur)
@Deprecated
public Quad(java.lang.String texture,
org.openmali.vecmath2.Tuple3f[] vertices,
org.openmali.vecmath2.TexCoord2f[] textureCoords)
vertices - the vertices of the Quadtexture - the name of the texture (loaded with the TextureLoader)textureCoords - the texture coordinates for the Quad (ll, lr, ul, ur)
@Deprecated
public Quad(org.openmali.vecmath2.Tuple3f[] vertices,
org.openmali.vecmath2.Colorf color)
vertices - the vertices of the Quadcolor - the color to use for coloring this Quad
@Deprecated
public Quad(org.openmali.vecmath2.Tuple3f[] vertices,
java.lang.String texture)
vertices - the vertices of the Quadtexture - the name of the texture (loaded with the TextureLoader)@Deprecated public Quad(org.openmali.vecmath2.Tuple3f[] vertices)
vertices - the vertices of the Quad| Method Detail |
|---|
@Deprecated public void update(org.openmali.vecmath2.Tuple3f[] vertices)
setVertexCoords(Tuple3f[]), which abstracts the internal vertex order.
vertices - The new vertices (ll, lr, ul, ur)
@Deprecated
public void update(org.openmali.vecmath2.Tuple3f ll,
org.openmali.vecmath2.Tuple3f lr,
org.openmali.vecmath2.Tuple3f ul,
org.openmali.vecmath2.Tuple3f ur)
setVertexCoords(Tuple3f, Tuple3f, Tuple3f, Tuple3f), which abstracts the internal vertex order.
ll - New vertex-coord of the lower-left cornerlr - New vertex-coord of the lower-right cornerur - New vertex-coord of the upper-right cornerul - New vertex-coord of the upper-left corner
public void setVertexCoords(org.openmali.vecmath2.Tuple3f[] coords,
Geometry geom)
public void setVertexCoords(org.openmali.vecmath2.Tuple3f ll,
org.openmali.vecmath2.Tuple3f lr,
org.openmali.vecmath2.Tuple3f ur,
org.openmali.vecmath2.Tuple3f ul)
ll - New vertex-coord of the lower-left cornerlr - New vertex-coord of the lower-right cornerur - New vertex-coord of the upper-right cornerul - New vertex-coord of the upper-left cornerpublic void setVertexCoords(org.openmali.vecmath2.Tuple3f[] coords)
coords - The new vertex-coords (ll, lr, ur, ul)public void setColor(org.openmali.vecmath2.Colorf color)
color - the new colorpublic org.openmali.vecmath2.Colorf getColor()
public void setAlpha(float alpha)
public float getAlpha()
@Deprecated public void setTexturePosition(org.openmali.vecmath2.TexCoord2f[] textureCoordinates)
setTextureCoordinates(TexCoord2f[]) instead.
textureCoordinates - the texture coordinate for this Quad (ll, lr, ul, ur)public void setTextureCoordinates(org.openmali.vecmath2.TexCoord2f[] textureCoordinates)
textureCoordinates - the texture coordinate for this Quad (ll, lr, ur, ul)public void setTexture(Texture texture)
texture - the new Texture
public void setTexture(Texture texture,
org.openmali.vecmath2.TexCoord2f[] textureCoordinates)
texture - the new TexturetextureCoordinates - the texture coordinate for this Quad (ll, lr, ur, ul)
public void setTexture(java.lang.String texture,
org.openmali.vecmath2.TexCoord2f[] textureCoordinates)
texture - the new Texture resourcetextureCoordinates - the texture coordinate for this Quad (ll, lr, ur, ul)public void setTexture(java.lang.String texture)
texture - the new Texture resourcepublic Texture getTexture()
public TriangleFanArray getGeometry()
getGeometry in class Shape3Dprotected TriangleFanArray createGeometry()
protected void generateNormals(Geometry geom)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||