38 cuiLoadingScreen::cuiLoadingScreen(
void)
40 strcpy(_strMessage,
"Loading...");
43 cuiLoadingScreen::~cuiLoadingScreen(
void)
47 void cuiLoadingScreen::ctlCreate()
49 laSettings* s = ::laSystemIntegrator::getIntegrator()->getSettings();
50 double w = s->graphics_resolution_w;
51 double h = s->graphics_resolution_h;
53 _LogoTex.load(
"ron_logo.bmp");
55 _Indicator.setColor(
laRGB(250,255,230));
56 _Indicator.setSize(s->graphics_resolution_w/2, 20);
57 _Indicator.setMaxValue(100);
61 void cuiLoadingScreen::ctlDiscard()
65 void cuiLoadingScreen::draw()
67 laSettings* s = ::laSystemIntegrator::getIntegrator()->getSettings();
68 laRenderer* r = ::laSystemIntegrator::getIntegrator()->getRenderer();
69 double w = s->graphics_resolution_w;
70 double h = s->graphics_resolution_h;
75 r->styleSet(
laRGB(0,0,0));
76 r->drawFlatBox2(laPoint3(0,0), laPoint3(w,h), laUV(0,0), laUV(1,1));
80 r->styleSet(
laRGB(255,255,255));
81 r->drawFlatBox2(laPoint3((w-_LogoTex.w)/2, h/3 - _LogoTex.h/2), laPoint3(_LogoTex.w, _LogoTex.h), laUV(0,0), laUV(1,1));
83 _Indicator.draw(r, laPoint3(w/4, h-h/4));
85 r->getFontManager()->getFont(1)->ctlAlignH(
M_AC);
86 r->getFontManager()->getFont(1)->ctlSize(18);
88 r->styleSet(
laRGB(250,255,230,150));
89 r->getFontManager()->getFont(1)->drawText(laPoint3(w/2, h-h/4+50), _strMessage);
94 void cuiLoadingScreen::message(
double inc,
char* strText, ...)
102 va_start(ap, strText);
103 vsprintf(text, strText, ap);
106 strcpy(_strMessage, text);
virtual void modeTexture(M_BOOL bOn)=0
Enable/disable texturing.
#define M_AC
Text align center.
Virtual interface for the Engine graphics renderer.
virtual void modeInterface()=0
Switch to interface rendering (2D projection mode)