void AwesomeSilkApp::update() { // update the Awesomium engine mWebCorePtr->Update(); // create or update our OpenGL Texture from the webview if( ! mWebViewPtr->IsLoading() && ph::awesomium::isDirty( mWebViewPtr ) ) { try { // set texture filter to NEAREST if you don't intend to transform (scale, rotate) it gl::Texture::Format fmt; fmt.setMagFilter( GL_NEAREST ); // get the texture using a handy conversion function mWebTexture = ph::awesomium::toTexture( mWebViewPtr, fmt ); } catch( const std::exception &e ) { console() << e.what() << std::endl; } // update the window title to reflect the loaded content char title[1024]; mWebViewPtr->title().ToUTF8( title, 1024 ); app::getWindow()->setTitle( title ); } }
void _TBOX_PREFIX_App::update() { // update the Awesomium engine mWebCorePtr->Update(); // create or update our OpenGL Texture from the webview if( ! mWebViewPtr->IsLoading() && ph::awesomium::isDirty( mWebViewPtr ) ) { try { // set texture filter to NEAREST if you don't intend to transform (scale, rotate) it gl::Texture::Format fmt; fmt.setMagFilter( GL_NEAREST ); // get the texture using a handy conversion function mWebTexture = ph::awesomium::toTexture( mWebViewPtr, fmt ); } catch( const std::exception &e ) { console() << e.what() << std::endl; } } }