|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.hardcorepawn.SuperTri
public class SuperTri
This class allows you to create a large number of triangles in OPENGL mode in processing.
| Constructor Summary | |
|---|---|
SuperTri(processing.core.PApplet p)
Create a new SuperTri object like: |
|
| Method Summary | |
|---|---|
int |
addPoint(float x,
float y,
float z,
float nx,
float ny,
float nz,
float r,
float g,
float b,
float a)
Add a new point to the list. |
int |
addPointPlain(float x,
float y,
float z)
Synonym for addPoint(x,y,z,0,0,1,1,1,1,1); |
int |
addPointWithColour(float x,
float y,
float z,
float r,
float g,
float b,
float a)
Synonym for addPoint(x,y,z,0,0,1,r,g,b,a); |
int |
addPointWithNormal(float x,
float y,
float z,
float nx,
float ny,
float nz)
Synonym for addPoint(x,y,z,nx,ny,nz,1,1,1,1); |
void |
addTri(int point1,
int point2,
int point3)
Create a triangle out of the 3 supplied point IDs. |
void |
draw()
Draws the triangles. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SuperTri(processing.core.PApplet p)
SuperTri p;
void setup()
{
//size etc...
p=new SuperTri(this);
}
p - | Method Detail |
|---|
public int addPointPlain(float x,
float y,
float z)
public int addPointWithColour(float x,
float y,
float z,
float r,
float g,
float b,
float a)
public int addPointWithNormal(float x,
float y,
float z,
float nx,
float ny,
float nz)
public int addPoint(float x,
float y,
float z,
float nx,
float ny,
float nz,
float r,
float g,
float b,
float a)
x,y,z - the position in spacenx,ny,nz - the normals of the pointr,g,b,a - the 0..1 colour values
addTri(int,int,int)
public void addTri(int point1,
int point2,
int point3)
point1 - point2 - point3 - public void draw()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||