// ----------------------------------------------------------------------------- SceneManager::SceneManager(const glm::ivec2 screenSize, SceneContainer *container) : m_world(container->getWorld()), m_camera(container->getCamera()), #ifndef WINDOWS m_textManager(TextManager(FONT_PATH + FONT_FILE, FONT_HEIGHT, screenSize)), #endif m_drawer(screenSize), m_shadowManager(screenSize), m_BACKGROUND_COLOR(container->getBackgroundColor()), m_positionMutex(SDL_CreateMutex()) { m_lightMask = (2 << (m_world->getLightsNumber() - 1)) - 1; setupProjection(screenSize); initGPU(container); glClearColor(m_BACKGROUND_COLOR.x, m_BACKGROUND_COLOR.y, m_BACKGROUND_COLOR.z, m_BACKGROUND_COLOR.w); checkOpenGLError("GLInitializer: glClearColor"); }
pushInput(code); } void TextManager::showPicture(char * filename, int posX, int posY){ Robot.pause(); Robot._drawBMP(filename,posX,posY); Robot.play(); } void TextManager::getPGMtext(int seq){ //It takes a string from program space, and fill it //in the buffer //if(in hello user example){ if(true){ strcpy_P(PGMbuffer,(char*)pgm_read_word(&(::scripts_Hello_User[seq]))); } } void TextManager::writeScript(int seq, int line, int col){ //print a string from program space to a specific line, //column on the LCD //first fill the buffer with text from program space getPGMtext(seq); //then print it to the screen textManager.writeText(line,col,PGMbuffer); } TextManager textManager=TextManager();