protected override void SetupDrawAttributes(UWB_DrawHelper drawHelper) { base.SetupDrawAttributes(drawHelper); drawHelper.setColor1(mFlatColor); drawHelper.setColor2(mShadingColor); drawHelper.setShadeMode(mShadeMode); }
protected override void DrawPrimitive(eLevelofDetail lod, UWB_DrawHelper drawHelper) { Vector3 origin = new Vector3(); Vector3 xaxis = new Vector3(m_size, 0, 0); Vector3 yaxis = new Vector3(0, m_size, 0); Vector3 zaxis = new Vector3(0, 0, m_size); eLevelofDetail oldLod = drawHelper.getLod(); drawHelper.setLod(lod); drawHelper.setColor1(Color.Red); drawHelper.drawLine(origin, xaxis); drawHelper.setColor1(Color.Green); drawHelper.drawLine(origin, yaxis); drawHelper.setColor1(Color.Blue); drawHelper.drawLine(origin, zaxis); drawHelper.setLod(oldLod); }
public void DrawWCWindow(UWB_DrawHelper drawHelper) { drawHelper.resetAttributes(); drawHelper.setShadeMode(eShadeMode.smFlat); drawHelper.setFillMode(eFillMode.fmWireframe); drawHelper.setColor1(new Color(new Vector3(1.0f, 0.0f, 0.0f))); drawHelper.drawRectangle(WCWindowMin, WCWindowMax); }
protected override void DrawPrimitive(eLevelofDetail lod, UWB_DrawHelper drawHelper) { Vector3 origin = new Vector3(); Vector3 xaxis = new Vector3(m_size, 0, 0); Vector3 yaxis = new Vector3(0, m_size, 0); Vector3 zaxis = new Vector3(0, 0, m_size); eLevelofDetail oldLod = drawHelper.getLod(); drawHelper.setLod(lod); drawHelper.setColor1(Color.Red); drawHelper.drawLine(origin, xaxis); drawHelper.setColor1(Color.Green); drawHelper.drawLine(origin, yaxis); drawHelper.setColor1(Color.Blue); drawHelper.drawLine(origin, zaxis); drawHelper.setLod(oldLod); }
protected override void SetupDrawAttributes(UWB_DrawHelper drawHelper) { base.SetupDrawAttributes(drawHelper); drawHelper.setColor1(mFlatColor); drawHelper.setColor2(mShadingColor); drawHelper.setShadeMode(mShadeMode); drawHelper.setFillMode(mFillMode); }
public void drawPivot(UWB_DrawHelper drawHelper, float size) { drawHelper.resetAttributes(); drawHelper.setColor1(new Color(new Vector3(1f, 1f, 1f))); drawHelper.setColor2(new Color(new Vector3(0, 0, 1f))); drawHelper.setFillMode(eFillMode.fmSolid); drawHelper.setShadeMode(eShadeMode.smGouraud); drawHelper.drawCircle(mPivot, size); }
public void drawPivot(UWB_DrawHelper drawHelper, float size) { drawHelper.resetAttributes(); drawHelper.setColor1(new Color(new Vector3(1f, 1f, 1f))); drawHelper.setColor2(new Color(new Vector3(0, 0, 1f))); drawHelper.setFillMode(eFillMode.fmSolid); drawHelper.setShadeMode(eShadeMode.smGouraud); drawHelper.drawCircle(mPivot, size); }
public void drawBoundingVolume(eLevelofDetail lod, UWB_DrawHelper drawHelper, Color color) { UWB_BoundingVolume boundingVolume = getBoundingVolume(lod); if (boundingVolume != null && drawHelper != null) { drawHelper.resetAttributes(); drawHelper.setColor1(color); drawHelper.setShadeMode(eShadeMode.smFlat); drawHelper.setFillMode(eFillMode.fmWireframe); boundingVolume.Draw(ref drawHelper); } }
protected virtual void SetupDrawAttributes(UWB_DrawHelper drawHelper) { drawHelper.resetAttributes(); drawHelper.setColor1(mFlatColor); drawHelper.SetMaterial(ref m_Material); drawHelper.EnableBlending(m_bBlendingEnabled); drawHelper.EnableLighting(m_bLightingEnabled); drawHelper.SetTextureInfo(ref m_TexFileName); if (m_TexFileName != null) { drawHelper.EnableTexture(m_bTexturingEnabled); } }
protected bool GetNodeBoundsHelper(ref UWB_SceneNode pSearchNode, ref UWB_BoundingBox box, ref UWB_DrawHelper helper, int level, bool bDraw) { bool found = false; if (Object.ReferenceEquals(this, pSearchNode)) { box = this.GetBounds(ref helper, bDraw); found = true; } else { helper.pushModelTransform(); { level++; this.getXFormInfo().setupModelStack(helper); int count = this.numChildren(); for (int i = 0; i < count; i++) { UWB_SceneNode pChildNode = this.getChildNode(i); if (pChildNode.GetNodeBoundsHelper(ref pSearchNode, ref box, ref helper, level, bDraw)) { found = true; break; } } level--; } helper.popModelTransform(); } if (0 == level && found && bDraw) { helper.resetAttributes(); helper.setColor1(new Color(0, 0, 255)); helper.setShadeMode(eShadeMode.smFlat); helper.setFillMode(eFillMode.fmWireframe); box.Draw(ref helper); } return(found); }
protected override void SetupDrawAttributes(UWB_DrawHelper drawHelper) { base.SetupDrawAttributes(drawHelper); drawHelper.setColor1(mFlatColor); drawHelper.setPointSize(mPointSize); }
public void DrawWCWindow(UWB_DrawHelper drawHelper) { drawHelper.resetAttributes(); drawHelper.setShadeMode(eShadeMode.smFlat); drawHelper.setFillMode(eFillMode.fmWireframe); drawHelper.setColor1(new Color(new Vector3(1.0f, 0.0f, 0.0f))); drawHelper.drawRectangle(WCWindowMin, WCWindowMax); }
public void drawBoundingVolume(eLevelofDetail lod, UWB_DrawHelper drawHelper, Color color) { UWB_BoundingVolume boundingVolume = getBoundingVolume(lod); if (boundingVolume != null && drawHelper != null) { drawHelper.resetAttributes(); drawHelper.setColor1(color); drawHelper.setShadeMode(eShadeMode.smFlat); drawHelper.setFillMode(eFillMode.fmWireframe); boundingVolume.Draw(ref drawHelper); } }
protected virtual void SetupDrawAttributes(UWB_DrawHelper drawHelper) { drawHelper.resetAttributes(); drawHelper.setColor1(mFlatColor); drawHelper.SetMaterial(ref m_Material); drawHelper.EnableBlending(m_bBlendingEnabled); drawHelper.EnableLighting(m_bLightingEnabled); drawHelper.SetTextureInfo(ref m_TexFileName); if (m_TexFileName != null) drawHelper.EnableTexture(m_bTexturingEnabled); }
protected bool GetNodeBoundsHelper(ref UWB_SceneNode pSearchNode, ref UWB_BoundingBox box, ref UWB_DrawHelper helper, int level, bool bDraw) { bool found = false; if( Object.ReferenceEquals(this, pSearchNode)) { box = this.GetBounds( ref helper, bDraw ); found = true; } else { helper.pushModelTransform(); { level++; this.getXFormInfo().setupModelStack(helper); int count = this.numChildren(); for(int i=0; i<count; i++) { UWB_SceneNode pChildNode = this.getChildNode( i ); if( pChildNode.GetNodeBoundsHelper( ref pSearchNode, ref box, ref helper, level, bDraw ) ) { found = true; break; } } level--; } helper.popModelTransform(); } if (0 == level && found && bDraw) { helper.resetAttributes(); helper.setColor1(new Color(0,0,255)); helper.setShadeMode(eShadeMode.smFlat); helper.setFillMode(eFillMode.fmWireframe); box.Draw(ref helper); } return found; }
protected override void SetupDrawAttributes(UWB_DrawHelper drawHelper) { base.SetupDrawAttributes(drawHelper); drawHelper.setColor1(mFlatColor); drawHelper.setPointSize(mPointSize); }