Animation/Games in Java
Submitted by jeffheaton on Wed, 01/09/2008 - 08:48
Java can be applied to many uses. However, one of the most fun
applications of Java is to use it to create small animated applets. In
this series of articles I will show you how to create animated Java
apples. Some of them will be non-interactive, such as a background
animated display. Others will be fully interactive, such as a video
game. I will begin from the very beginning and explain the basics of
Java 2D animation, and end the series with complex applet-based video
games.













gif header
( message edit: answered )
I need to load raw image data from a .dll I have 80% ready for first trial compile, the image is supplied in one format: 8-bit greyscale DIB. I read
/**
* @author Jeff Heaton(http://www.jeffheaton.com)
* @version 1.0
*/
class BinaryFile
where at line 274-277
if (_endian == BIG_ENDIAN)
result = ((a << 8) | b);
else
result = (a | (b << 8));
addresses the endian issue. Does this need to be done on ram-resident image data? Additionally, there are some image classes ( Java classes ) that I have noted in my work - on the basis of a claim in the documentation that those classes work on image data as image data, not as numeric data where signed issue hampers effectiveness.
Also, I opened BinaryFile.java and BinaryExample.java in my editor trying to find basic information on extracting image data to a workable format from data supplied by the equipment as DIB. It is my intent to load a paper document into ram from the scanner, whatever if any file semantics seen by the user will be done *after* reduction to a simple text data format. I am working at saturation of what I can absorb and need to get on with OCR - I have my java wrapper code compiled and ran javap on that to get the .h for the .dll + getting the compiler switches to do a first build on the .dll - it will be slow going as Canadian Mind Products reports that to reload the .dll after rebuilding on current retail kernels it is needful to go through a full powerdown and re-boot to get the dll to reload.
I think I can deal with most of the issues as something like shift and binary or can be reduced with bench runs but your skills are powerful adjuncts on the issue of "endianess" in ram-resident only data and how to work the pallet against the image triplets to attain a stream of single data points on which I can do experimental work from your Java book on AI.