| 42 | mLines.beginUpdate(0); |
| 43 | } |
| 44 | void DefaultDebugDrawer::beginAxes() |
| 45 | { |
| 46 | if (mAxes.getSections().empty()) |
| 47 | { |
| 48 | const char* matName = "Ogre/Debug/AxesMat"; |
| 49 | auto mat = MaterialManager::getSingleton().getByName(matName, RGN_INTERNAL); |
| 50 | if (!mat) |
| 51 | { |
| 52 | mat = MaterialManager::getSingleton().create(matName, RGN_INTERNAL); |
| 53 | Pass* p = mat->getTechnique(0)->getPass(0); |
| 54 | p->setLightingEnabled(false); |
| 55 | p->setPolygonModeOverrideable(false); |
| 56 | p->setVertexColourTracking(TVC_AMBIENT); |
| 57 | p->setSceneBlending(SBT_TRANSPARENT_ALPHA); |
| 58 | p->setCullingMode(CULL_NONE); |
| 59 | p->setDepthWriteEnabled(false); |
| 60 | p->setDepthCheckEnabled(false); |
| 61 | } |
| 62 | |
| 63 | mAxes.setBufferUsage(HBU_CPU_TO_GPU); |
| 64 | mAxes.begin(mat); |
| 65 | } |
| 66 | else if (mAxes.getCurrentVertexCount() == 0) |
| 67 | mAxes.beginUpdate(0); |
| 68 | } |
| 69 | void DefaultDebugDrawer::drawWireBox(const AxisAlignedBox& aabb, const ColourValue& colour) |
| 70 | { |
| 71 | beginLines(); |
nothing calls this directly
no test coverage detected