As mobile devices grow rich in hardware and software technology that delivers real consumer value, and as new smart phones emerge that feature integrated cameras and MP3 players, multimedia messaging, and other support for digital media, the Java 2 Platform, Micro Edition (J2ME) will become increasingly important - particularly software stacks based on the Connected Limited Device Configuration (CLDC) and the Mobile Information Device Profle (MIDP). As more and more phones come equipped with J2ME CLDC/MIDP, a new wave of innovation will make the mobile landscape more and more attractive. This tech tip provides a glimpse into the future of J2ME-based multimedia, including a way to convert Macromedia Flash files into J2ME MIDlets, and tools for using vector graphics. Rich Client Technology To give users a desktop-like experience on their mobile devices requires rich client technology. Such technology boosts the usefulness of mobile devices and drives new opportunities for application developers, content providers, and media and communication companies. The J2ME Web Services API (WSA), JSR 172 in the Java Community Process (JCP), gives mobile applications written in the Java programming language access to any software service that conforms to web services standards, running on any kind of platfrom anywhere on the network. This breadth of application interoperability will provide the potential for new levels of productivity. WSA includes optional packages that enable J2ME-based applications to parse XML and invoke remote web services. As a motivating example, consider the task of developing a MIDlet that would let the user play chess on a mobile phone. A central design decision will be where to put the game logic. The two likeliest options:
Clearly, there are trade-offs here. In a self-contained MIDlet, the user incurs no airtime charges after downloading the game, and neither the MIDlet nor the player has to deal with a lost connection in mid-game. In the client-server model, the web service that calculates the opponent's moves is available to clients running on any platform, not just J2ME. Not only does the web service have a broader market, but it has much greater resources, including the processing power to be a much more challenging opponent. How should the chess board be implemented? You could code it yourself in a MIDlet, but for a more interactive result you could implement it using Macromedia Flash. If you do, how would it run on a cell phone? Converting Flash Files to MIDlets Flash is not available on all mobile devices - but one company has seen in that fact an opportunity rather than an obstacle: Finland's Animoi. Its Animoi Content Converter uses a J2ME-based player to power interactive content for mobile devices. This enables Flash developers to take advantage of their existing skills to produce interactive multimedia content and applications for J2ME-enabled mobile devices.
Animoi Content Converter consumes Flash files and converts them into ready-to-run MIDlets with one click of a button. Two kinds of professionals will find this tool useful:
The Right, Standard Solution The disadvantages of Flash are that it's not available on all cellular phones and it's not a standard. Developers with hands-on experience with J2ME can use the Mobile Media API (MMAPI) to develop graphics-rich interactive applications. The MMAPI, however, doesn't address the control of vector graphics formats. The World Wide Web Consortium (W3C) has developed Scalable Vector Graphics (SVG), a language for describing two-dimensional graphics in XML. It supports three types of graphic objects: text, images, and vector graphic shapes such as straight lines and curves. A lightweight version, SVG Tiny, has been designed for mobile devices. The intent of a JCP specification currently under development, JSR 226: Scalable 2D Vector Graphics API for J2ME, is to define an optional package for rendering both scalable 2D vector graphics and image files in SVG Tiny format on J2ME devices. For More Information
Acknowledgments Special thanks to Vincent Hardy of Sun Microsystems, whose feedback helped me improve this tech tip. About the author Qusay H. Mahmoud provides Java consulting and training services. He has published dozens of articles on Java, and is the author of Distributed Programming with Java (Manning Publications, 1999) and Learning Wireless Java (O'Reilly, 2002). | ||||||||
Oracle is reviewing the Sun product roadmap and will provide guidance to customers in accordance with Oracle's standard product communication policies. Any resulting features and timing of release of such features as determined by Oracle's review of roadmaps, are at the sole discretion of Oracle. All product roadmap information, whether communicated by Sun Microsystems or by Oracle, does not represent a commitment to deliver any material, code, or functionality, and should not be relied upon in making purchasing decisions. It is intended for information purposes only, and may not be incorporated into any contract.
|
| ||||||||||||