|
|
@ -30,11 +30,12 @@ using namespace NLMISC;
|
|
|
|
using namespace std;
|
|
|
|
using namespace std;
|
|
|
|
using namespace NL3D;
|
|
|
|
using namespace NL3D;
|
|
|
|
|
|
|
|
|
|
|
|
CViewRenderer::CViewRenderer( NL3D::UDriver *driver )
|
|
|
|
CViewRenderer::CViewRenderer( NL3D::UDriver *driver, NL3D::UTextContext *textcontext )
|
|
|
|
{
|
|
|
|
{
|
|
|
|
setup();
|
|
|
|
setup();
|
|
|
|
|
|
|
|
|
|
|
|
this->driver = driver;
|
|
|
|
this->driver = driver;
|
|
|
|
|
|
|
|
this->textcontext = textcontext;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
CViewRenderer::~CViewRenderer()
|
|
|
|
CViewRenderer::~CViewRenderer()
|
|
|
@ -155,7 +156,7 @@ void CViewRenderer::init()
|
|
|
|
// Init all renderBuffer
|
|
|
|
// Init all renderBuffer
|
|
|
|
for(uint i=0;i<VR_NUM_LAYER;i++)
|
|
|
|
for(uint i=0;i<VR_NUM_LAYER;i++)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
_StringRBLayers[i]= TextContext->createRenderBuffer();
|
|
|
|
_StringRBLayers[i]= textcontext->createRenderBuffer();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
@ -200,6 +201,11 @@ NL3D::UDriver* CViewRenderer::getDriver(){
|
|
|
|
return driver;
|
|
|
|
return driver;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void CViewRenderer::setTextContext(NL3D::UTextContext *textcontext)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
this->textcontext = textcontext;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// ***************************************************************************
|
|
|
|
// ***************************************************************************
|
|
|
|
void CViewRenderer::SImage::setupQuadUV(bool flipv, uint8 rot, CQuadColorUV &dest)
|
|
|
|
void CViewRenderer::SImage::setupQuadUV(bool flipv, uint8 rot, CQuadColorUV &dest)
|
|
|
|
{
|
|
|
|
{
|
|
|
@ -1211,9 +1217,9 @@ void CViewRenderer::flush ()
|
|
|
|
|
|
|
|
|
|
|
|
// **** Display Computed Strings of this layer
|
|
|
|
// **** Display Computed Strings of this layer
|
|
|
|
if (_WorldSpaceTransformation)
|
|
|
|
if (_WorldSpaceTransformation)
|
|
|
|
TextContext->flushRenderBufferUnProjected(_StringRBLayers[layerId], false);
|
|
|
|
textcontext->flushRenderBufferUnProjected(_StringRBLayers[layerId], false);
|
|
|
|
else
|
|
|
|
else
|
|
|
|
TextContext->flushRenderBuffer(_StringRBLayers[layerId]);
|
|
|
|
textcontext->flushRenderBuffer(_StringRBLayers[layerId]);
|
|
|
|
|
|
|
|
|
|
|
|
// flushed
|
|
|
|
// flushed
|
|
|
|
_EmptyLayer[layerId]= true;
|
|
|
|
_EmptyLayer[layerId]= true;
|
|
|
|