Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 73: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 74: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 75: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 76: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 77: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 78: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
package BlackCarbon.MarbleTilt; import android.app.Activity; import android.app.Application; import android.content.res.Resources; import android.graphics.Canvas; import android.os.Bundle; import android.os.Handler; import android.os.HandlerThread; import android.os.Message; import android.opengl.GLSurfaceView; import android.view.KeyEvent; import android.view.SurfaceHolder; import android.view.Window; import javax.microedition.khronos.egl.EGLConfig; import javax.microedition.khronos.opengles.GL10; import BlackCarbon.Library.Device; import BlackCarbon.Library.Matrix; import BlackCarbon.Library.RenderBuffer; import BlackCarbon.Library.Vector; import BlackCarbon.Library.Texture; import BlackCarbon.Library.Font; class Game { public Game() { mGame = this; } public void Init(GL10 gl, Resources res) { mDevice = new Device(gl, res); mRB = mDevice.CreateRenderBuffer(); mRB.CreateQuad(null); mTexture = mDevice.CreateTexture("mini"); mFont = mDevice.CreateFont("mini"); } public boolean Update() { return true; } public void Render() { mDevice.Begin(); Matrix r1 = new Matrix(); r1.SetIdentity(); r1.SetRotateY(mAngle); Matrix r2 = new Matrix(); r2.SetIdentity(); r2.SetRotateX(mAngle*0.25f); Matrix m = new Matrix(); m.SetIdentity(); //m.SetScale(new Vector(0.5f, 0.5f, 0.5f)); m = m.Multiply(r1); m = m.Multiply(r2); m.SetTranslation(new Vector(0, 0, -3.0f)); mDevice.SetMatrix(m, Device.MatrixMode.Model); mDevice.Bind(mTexture); mDevice.Render(mRB); mAngle += 0.01f; // lets draw some text Matrix textTransform = new Matrix(); textTransform.SetIdentity(); textTransform.SetTranslation(new Vector(-1.8f, -1.8f, -3.0f)); mFont.RenderText(mDevice, textTransform, "Hello World!"); mDevice.End(); } public void Resize(int width, int height) { mDevice.Resize(width, height); } static Game Get() { return mGame; } static Game mGame; private Font mFont; private Texture mTexture; private float mAngle; private Device mDevice; private RenderBuffer mRB; } class AppThread extends Thread { AppThread(AppEntry application) { mApplication = application; } public SurfaceHolder GetSurface() { return mApplication.mView.getHolder(); } @Override public void run() { boolean bRunning = true; while (bRunning) { bRunning = Game.Get().Update(); try { sleep(20); } catch (InterruptedException e) { // TODO Auto-generated catch block e.printStackTrace(); } } /* SurfaceHolder surfaceHolder = GetSurface(); boolean bRunning = true; while (bRunning) { Canvas c = null; try { c = surfaceHolder.lockCanvas(null); synchronized (surfaceHolder) { //if (mMode == STATE_RUNNING) bRunning = Game.Get().Update(); //Game.Get().Render(); done below! } } finally { // do this in a finally so that if an exception is thrown // during the above, we don't leave the Surface in an // inconsistent state if (c != null) { surfaceHolder.unlockCanvasAndPost(c); } } }*/ } public AppEntry mApplication; } class AppHandler extends Handler { @Override public void handleMessage(Message msg) { super.handleMessage(msg); } } class AppView extends GLSurfaceView implements SurfaceHolder.Callback { public AppView(Application app) { super(app); } @Override public boolean onKeyDown(int keyCode, KeyEvent event) { return super.onKeyDown(keyCode, event); } private AppHandler mHandler = new AppHandler(); } class AppRenderer implements GLSurfaceView.Renderer { public AppRenderer(Activity app) { mActivity = app; } public void onSurfaceCreated(GL10 gl, EGLConfig config) { try { Game.Get().Init(gl, mActivity.getResources()); } catch (Exception e) { e.printStackTrace(); } } public void onDrawFrame(GL10 gl) { Game.Get().Render(); } public void onSurfaceChanged(GL10 gl, int width, int height) { Game.Get().Resize(width, height); } private Activity mActivity; } public class AppEntry extends Activity { /** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); mGame = new Game(); requestWindowFeature(Window.FEATURE_NO_TITLE); mView = new AppView(getApplication()); mRenderer = new AppRenderer(this); mView.setRenderer(mRenderer); setContentView(mView); // register our interest in hearing about changes to our surface SurfaceHolder holder = mView.getHolder(); holder.addCallback(mView); mThread = new AppThread(this); mThread.start(); } public Game mGame; public AppView mView; public AppRenderer mRenderer; public AppThread mThread; }