remove graphic texture and "why this?"
This commit is contained in:
parent
c3018a9251
commit
a37889886c
1 changed files with 17 additions and 16 deletions
|
@ -517,8 +517,8 @@ uint32_t randomtexturedata[256*256];
|
||||||
int main( int argc, char ** argv )
|
int main( int argc, char ** argv )
|
||||||
{
|
{
|
||||||
//Heightmap int x, y;
|
//Heightmap int x, y;
|
||||||
double ThisTime;
|
//why this? double ThisTime;
|
||||||
double LastFPSTime = OGGetAbsoluteTime();
|
//why this? double LastFPSTime = OGGetAbsoluteTime();
|
||||||
|
|
||||||
Log( "Starting Up" );
|
Log( "Starting Up" );
|
||||||
|
|
||||||
|
@ -571,7 +571,7 @@ int main( int argc, char ** argv )
|
||||||
CNFGHandleInput();
|
CNFGHandleInput();
|
||||||
//SENSORSTURFF AccCheck();
|
//SENSORSTURFF AccCheck();
|
||||||
|
|
||||||
if( suspended ) { usleep(50000); continue; }
|
if( suspended ) { usleep(1000000); continue; }
|
||||||
|
|
||||||
//webview // RunCallbackOnUIThread( (void(*)(void*))WebViewRequestRenderToCanvas, &MyWebView );
|
//webview // RunCallbackOnUIThread( (void(*)(void*))WebViewRequestRenderToCanvas, &MyWebView );
|
||||||
//webview // RunCallbackOnUIThread( CheckWebView, &MyWebView );
|
//webview // RunCallbackOnUIThread( CheckWebView, &MyWebView );
|
||||||
|
@ -638,26 +638,27 @@ int main( int argc, char ** argv )
|
||||||
//webview CNFGPenX = 0; CNFGPenY = 100;
|
//webview CNFGPenX = 0; CNFGPenY = 100;
|
||||||
//webview // CNFGDrawText( fromJSBuffer, 6 );
|
//webview // CNFGDrawText( fromJSBuffer, 6 );
|
||||||
|
|
||||||
int x, y;
|
//graphic-random-texture int x, y;
|
||||||
for( y = 0; y < 256; y++ )
|
//graphic-random-texture for( y = 0; y < 256; y++ )
|
||||||
for( x = 0; x < 256; x++ )
|
//graphic-random-texture for( x = 0; x < 256; x++ )
|
||||||
randomtexturedata[x+y*256] = x | ((x*394543L+y*355+iframeno*3)<<8);
|
//graphic-random-texture randomtexturedata[x+y*256] = x | ((x*394543L+y*355+iframeno*3)<<8);
|
||||||
CNFGBlitImage( randomtexturedata, 100, 600, 256, 256 );
|
//graphic-random-texture CNFGBlitImage( randomtexturedata, 100, 600, 256, 256 );
|
||||||
|
|
||||||
//webview //WebViewNativeGetPixels( &MyWebView, webviewdata, 500, 500 );
|
//webview //WebViewNativeGetPixels( &MyWebView, webviewdata, 500, 500 );
|
||||||
//webview //CNFGBlitImage( webviewdata, 500, 640, 500, 500 );
|
//webview //CNFGBlitImage( webviewdata, 500, 640, 500, 500 );
|
||||||
|
|
||||||
frames++;
|
//why this? frames++;
|
||||||
//On Android, CNFGSwapBuffers must be called, and CNFGUpdateScreenWithBitmap does not have an implied framebuffer swap.
|
//On Android, CNFGSwapBuffers must be called, and CNFGUpdateScreenWithBitmap does not have an implied framebuffer swap.
|
||||||
CNFGSwapBuffers();
|
CNFGSwapBuffers();
|
||||||
|
|
||||||
ThisTime = OGGetAbsoluteTime();
|
// unclear if this would garanty a fram rate limiting?
|
||||||
if( ThisTime > LastFPSTime + 1 )
|
//why this? ThisTime = OGGetAbsoluteTime();
|
||||||
{
|
//why this? if( ThisTime > LastFPSTime + 1 )
|
||||||
printf( "FPS: %d\n", frames );
|
//why this? {
|
||||||
frames = 0;
|
//why this? printf( "FPS: %d\n", frames );
|
||||||
LastFPSTime+=1;
|
//why this? frames = 0;
|
||||||
}
|
//why this? LastFPSTime+=1;
|
||||||
|
//why this? }
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue