Monday, October 17, 2011

An Adventure in Porting a Java Applet to Android with no Previous Experience with Android - CodeProject

Check out this following article!

Introduction

This shows how I ported a Java Applet to Android app with no previous experience.

Background

I would like to thank several people instrumental in inspiring me to write this app.
In 1996, John Henckel from IBM posted a Java Applet, Impact.java, that is the heart of this app.
The general purpose of this application is to create 2D ball objects that have attributes of mass, size, color, coefficient of restitution and then place them in a medium with a degree of viscosity. The balls then interact with each other being attracted to each other by gravity and when they collide will rebound as a function of their coefficient of restitution. The user can also 'grab' the balls via the mouse and alter their movement.
I ported this Java Applet to Android and this article discusses the learning steps required and also highlights how fairly common Android features are implemented such as menus, sound, accelerometer reading, notifications, activities, intents, etc. The Android app extends the original applet by adding sound and use of the accelerometer sensors to affect the movement of the balls beyond the gravitational and frictional forces.




An Adventure in Porting a Java Applet to Android with no Previous Experience with Android - CodeProject

No comments: