Michael Bayne 45edaccf6d The plot, she is thick. The Nenya framework supports a MediaOverlay that can
render sprites and animations over the top of everything in the frame:
JComponents, MediaPanels anything we like. To support this, we have the
MediaOverlay tell the ActiveRepaintManager when it has dirtied an area of the
screen and it will mark that component as needing repainting. Peachy.

However, if a component decides on its own that it needs repainting, we need to
propagate that now dirty region up to the MediaOverlay so that it can repaint
anything that's above the just-repainted component on the same frame tick.
This also fixes a potential problem if a changed sprite dirties a component
which then repaints itself but the bounds of that component overlapped some
other sprite which was not going to be repainted on this tick.

There were also potential problems if components were put in the JLayeredPane
layers (which are "above" the normal components and MediaPanels but "below" the
MediaOverlay). They too should now properly dirty regions in the overlay.

It occurs to me though that if a MediaOverlay sprite is on top of a MediaPanel,
the MediaPanel will probably not properly propagate its dirty region to the
overlay because the MediaPanel is a frame participant, not a JComponent and its
repainting is handled by the FrameManager not the ActiveRepaintManager. I may
just use the sledgehammer approach and dirty in the media overlay the entire
bounds of a frame participant if it paints anything on a frame rather than try
to translated and propagate its underlying dirty regions up to the overlay.

Oh the twisty maze of passages we've created in trying to create an active
rendering system that works magically with Swing.


git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@566 ed5b42cb-e716-0410-a449-f6a68f950b19
2008-07-07 19:24:26 +00:00
2008-06-09 18:03:37 +00:00
2007-10-26 18:37:15 +00:00

The Nenya library
-----------------

The Nenya library provides various facilities for making networked multiplayer
games. It's various packages include:

  * geom, util - basic tools for doing data structure manipulation and some
    geometry math
  * resource - tools for bundling, deploying and managing media (images,
    sounds, etc.) with a game
  * media - a framework for doing "active" rendering in Java
  * media.image - tools for loading, caching, manipulating and displaying images
  * media.sound - tools for loading, caching, and playing audio
  * media.animation, media.sprite - works in concert with the active
    rendering system and provides tools for defining and manipulating
    sprites (graphical entities that follow paths) and animations
    (graphical entities that affect the display in other ways)
  * miso - a framework for defining and displaying isometrically rendered scenes
  * cast - a framework for defining and using recolorable, composited
    characters with different poses and actions

Documentation is somewhat sparse at the moment, but inspection of the code in
the tests/ directory shows examples of use of many features of the library.

Building
--------

Building the library is very simple. First ensure that the necessary third
party jar files are available in the lib/ directory. See lib/README for a list
of the necessary third party jar files and how to get them.

The library is built using Ant, a modern build tool written in and for Java. If
you aren't already using Ant for other projects, it can be found here:

  http://ant.apache.org/

Invoke ant with any of the following targets:

  all: builds the distribution files and javadoc documentation
  compile: builds only the class files (dist/classes)
  javadoc: builds only the javadoc documentation (dist/docs)
  dist: builds the distribution jar files (dist/*.jar)

Distribution
------------

The Nenya library is released under the LGPL. The most recent version of the
library is available here:

  http://www.threerings.net/code/nenya/

Contribution
------------

Contributions to Nenya are welcome. Read-only access to the subversion
repository is available at:

svn://code.threerings.net/narya/trunk

Patches can be mailed to Michael Bayne <mdb@threerings.net>.

Contact Information
-------------------

Nenya is actively developed by the scurvy dogs at Three Rings Design, Inc.
Contact Michael Bayne <mdb@threerings.net> with questions, comments and other
wordly endeavors.

$Id$
S
Description
Components for Java 2D, isometric and 3D games.
Readme 12 MiB
Languages
Java 78.8%
ActionScript 19.3%
Shell 1.5%
C 0.2%
Scala 0.1%