taking care of empty groups in PShapeOpenGL, some additional methods

This commit is contained in:
codeanticode
2012-05-24 15:46:04 +00:00
parent 6a57d75c6d
commit f498bbdcde
3 changed files with 81 additions and 9 deletions
+16 -1
View File
@@ -544,6 +544,8 @@ public class PGraphics extends PImage implements PConstants {
* based on the IMAGE or NORMALIZED.
*/
public int textureMode;
public int textureWrap;
/**
* Current horizontal coordinate for texture, will always
@@ -1063,7 +1065,20 @@ public class PGraphics extends PImage implements PConstants {
this.textureMode = mode;
}
// TODO: use this setting in GL renderer.
public void textureWrap(int wrap) {
this.textureWrap = wrap;
}
// TODO: do we need something like this to choose between
// point, linear and trilinear texture sampling?
//public void textureQualityt(int quality) {
// this.textureQuality = quality;
//}
/**
* ( begin auto-generated from texture.xml )
*
+22
View File
@@ -396,6 +396,28 @@ public class PShape implements PConstants {
return depth;
}
// TODO: need to discuss about these two (four).
public PVector getTop() {
return getTop(null);
}
public PVector getTop(PVector top) {
return top;
}
public PVector getBottom() {
return getBottom(null);
}
public PVector getBottom(PVector bottom) {
return bottom;
}
/**
* Return true if this shape is 2D. Defaults to true.