|
import java.awt.Rectangle;
|
import java.util.Enumeration;
|
import java.util.Vector;
|
|
class Attribute extends Object3D implements java.io.Serializable
|
{
|
static final long serialVersionUID = 1583170840242900475L;
|
|
Attribute()
|
{
|
cleardepth = false;
|
passtest = false;
|
backfacecull = false;
|
name = "Attribute";
|
}
|
|
Object3D deepCopy()
|
{
|
Attribute csg = new Attribute();
|
deepCopySelf(csg);
|
return csg;
|
}
|
|
protected void deepCopySelf(Object3D other)
|
{
|
super.deepCopySelf(other);
|
Attribute c = (Attribute) other;
|
|
c.cleardepth = cleardepth;
|
c.passtest = passtest;
|
c.backfacecull = backfacecull;
|
}
|
|
void createEditWindow(GroupEditor callee, boolean newWindow)
|
{
|
if (newWindow)
|
{
|
objectUI = new AttributeEditor(this, deepCopy(), callee);
|
} else
|
{
|
objectUI = new AttributeEditor(this, callee);
|
}
|
|
editWindow = objectUI.GetEditor();
|
}
|
|
void draw(iCameraPane display, Object3D /*Composite*/ root, boolean selected, boolean blocked)
|
{
|
if (hide)
|
return;
|
|
// super.draw(display, root, selected);
|
if (display.IsAmbientOcclusionOn())
|
return;
|
|
if (cleardepth)
|
display.ClearDepth();
|
display.DepthTest(!passtest);
|
PASSTEST = passtest;
|
// System.err.println("DISPLAY = " + display.drawMode);
|
// System.err.println("PASS TEST = " + PASSTEST);
|
//display.DepthWrite(!passtest);
|
if (backfacecull)
|
display.BackFaceCull(true);
|
else
|
display.BackFaceCull(display.BackFaceCullMode());
|
}
|
|
boolean cleardepth;
|
// boolean writedepth;
|
boolean passtest;
|
boolean backfacecull;
|
}
|