Merge branch 'develop' into modnark
This commit is contained in:
@@ -12,6 +12,7 @@ public:
|
||||
virtual ~Instance(void);
|
||||
std::string name;
|
||||
virtual void render(RenderDevice*);
|
||||
virtual void renderName(RenderDevice*);
|
||||
virtual void update();
|
||||
std::vector<Instance*> children; // All children.
|
||||
std::string getClassName();
|
||||
|
||||
@@ -550,6 +550,7 @@ void Application::onGraphics(RenderDevice* rd) {
|
||||
glEnableClientState(GL_COLOR_ARRAY);
|
||||
glEnableClientState(GL_NORMAL_ARRAY);
|
||||
_dataModel->getWorkspace()->render(rd);
|
||||
_dataModel->getWorkspace()->renderName(rd);
|
||||
glDisableClientState(GL_VERTEX_ARRAY);
|
||||
glDisableClientState(GL_COLOR_ARRAY);
|
||||
glDisableClientState(GL_NORMAL_ARRAY);
|
||||
@@ -759,4 +760,4 @@ void Application::QuitApp()
|
||||
|
||||
void Application::onCreate(HWND parentWindow)
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
@@ -30,6 +30,14 @@ void Instance::render(RenderDevice* rd)
|
||||
}
|
||||
}
|
||||
|
||||
void Instance::renderName(RenderDevice* rd)
|
||||
{
|
||||
for(size_t i = 0; i < children.size(); i++)
|
||||
{
|
||||
children[i]->renderName(rd);
|
||||
}
|
||||
}
|
||||
|
||||
void Instance::update()
|
||||
{
|
||||
}
|
||||
|
||||
@@ -107,6 +107,11 @@ void PartInstance::setRotVelocity(Vector3 v)
|
||||
}
|
||||
|
||||
void PartInstance::postRender(RenderDevice *rd)
|
||||
{
|
||||
// possibly descard this function...
|
||||
}
|
||||
|
||||
void PartInstance::renderName(RenderDevice *rd)
|
||||
{
|
||||
if(!nameShown)
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user