Mike Thomas
37b5e58961
If a MultiTileSprite overlaps with another item, take their render priorities into account.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@290 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-08-30 18:50:16 +00:00
Charlie Groves
11322269c2
Redraw seems to work correctly on the Mac now, so only invalidate the shifted region like on other platforms.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@288 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-08-28 17:07:39 +00:00
Mike Thomas
95c36c22a2
Explanatory comment.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@287 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-08-22 22:26:36 +00:00
Mike Thomas
b560a045cd
Add ability for a sprite to specify that it resides in a rectangular region of tiles rather than assuming all sprites only occupy one tile.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@286 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-08-22 22:24:54 +00:00
Mike Thomas
9d73fe0587
This needs to respect sprite offset.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@285 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-08-22 22:22:59 +00:00
Charlie Groves
e003d97535
Break the code for completing a fade into a method so subclasses can override it and do what they will when it finishes.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@284 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-08-10 22:00:50 +00:00
Michael Bayne
069fe85c70
A whole lot of widening, refactoring, thinking, rethinking and fiddling around
...
for what ultimately boils down adding this method to BundledComponentRepository:
@Override // from IMImageProvider
public Mirage getTileImage (String path, Rectangle bounds, Colorization[] zations)
{
// we don't need our images prepared for screen rendering
BufferedImage src = _imgr.getImage(getImageKey(path), zations);
if (bounds != null) {
src = src.getSubimage(bounds.x, bounds.y, bounds.width, bounds.height);
}
return new BufferedMirage(src);
}
So much fun to revisit code I wrote six years ago.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@283 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-08-03 22:04:04 +00:00
Michael Bayne
bbd5dd284e
Added version of getTile() that takes a rectangle into which to write the results.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@282 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-08-03 21:10:48 +00:00
Charlie Groves
205d57a7fe
Allow TileSetRuleSets to specify a custom tileset tag name, and use that to allow UniformTileSets as <uniformTileset> in addition to the existing SwissArmyTileSets as <tileset> in the bundle tasks.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@281 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-08-02 23:18:16 +00:00
Mike Thomas
1f435d582d
If our build process fails to properly trim a tile set, it's kinda a big deal, so throw a BuildException so ant hears about it and stops.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@280 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-07-30 20:59:32 +00:00
Dave Hoover
81dcd90c1a
Simplify and combine fading out for both moving and stationary sprites.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@276 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-07-18 18:47:37 +00:00
Dave Hoover
b5b3a5316e
Christmas comes but once a year, but svn keyword substitution day comes
...
whenever the urge strikes!
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@274 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-07-14 00:27:00 +00:00
Dave Hoover
f57c408d7f
If something goes wrong adding our tileset to the bundle, throw an exception so that
...
things fail & attract attentino, rather than trying to work around it and printing
a stack trace that will likely go unnoticed amidst a slew of other build messages.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@273 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-07-13 18:07:29 +00:00
Charlie Groves
7fdd8fee17
Add the ability to fade the sprite out without a path and fix fading out with a path so that it's actually fading out instead of fading in
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@272 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-07-11 23:49:04 +00:00
Charlie Groves
7efd53a76c
Use _minAlpha to figure out when to stop moving alpha down, don't readd the sprite in tick since shutdown is taking care of it also
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@271 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-07-09 22:49:48 +00:00
Charlie Groves
640b6fe1f6
Reset the up and down timers in reset and allow the maximum level of gleam and update frequency to be specified
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@269 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-06-29 22:41:52 +00:00
Dave Hoover
717dc79c02
Tabs -> spaces
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@268 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-06-26 00:07:47 +00:00
Michael Bayne
7a65a62927
Widening.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@262 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-06-14 17:42:52 +00:00
Dave Hoover
7ca448a91e
Let us optionally not auto-reposition TransformedMirages; it was being smart
...
for things like scales and rotates so 0,0 still meant the same place, but that
meant I couldn't just reposition something, since it would promptly undo the
transform I passed in.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@256 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-06-01 18:08:34 +00:00
Michael Bayne
97f6eb7c85
Switch to Java's logging facilities.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@254 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-30 01:18:06 +00:00
Michael Bayne
91c45db381
Let's do this in a way that allows more than a single value to be used in the
...
natural comparison.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@249 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-15 17:50:16 +00:00
Michael Bayne
acea29604d
Make AbstractMedia implement Comparable instead of using a comparator. Added
...
naturalOrder() which allows media to use a more consistent "same render order"
order resolution value than Object.hashCode().
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@248 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-15 17:45:18 +00:00
Michael Bayne
f7dfe51a9c
Oh yeah, we need to call that method.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@247 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-15 17:05:04 +00:00
Michael Bayne
9a30debf42
Type safety and widening.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@246 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-15 16:59:58 +00:00
Andrzej Kapolka
c755fd626a
To reduce shader state changes and compilations, just use the
...
four-bone-per-vertex configuration for all skinned meshes. Depending on
the models we have, it may be worth compiling a separate one for two
bones per vertex. Added a hook to customize the material color (for
per-vertex colors, e.g.)
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@245 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-15 00:55:19 +00:00
Andrzej Kapolka
124af1e0b1
Use a fragment shader as well as a vertex shader for the skinned meshes.
...
I tracked the ATI slowdown down to using a vertex shader in combination
with fixed function fog. Also cleaned up ShaderConfig a little.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@244 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-14 20:13:39 +00:00
Andrzej Kapolka
6b07087c31
32 matrices is just a feeeeew two many for ATI cards, but of course
...
their drivers can't do anything useful like report an error; they just
silently screw up. Limiting it to 31 makes it work, but there's still a
strange slowdown issue (and it's not that the shaders are being run in
software, but it's worth checking for that anyway).
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@243 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-12 00:57:35 +00:00
Michael Bayne
12e17a9e33
Remove debug logging.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@242 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-11 23:28:00 +00:00
Andrzej Kapolka
82ba950111
Go back to using byte buffers; that wasn't the problem.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@241 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-11 18:30:51 +00:00
Andrzej Kapolka
fd192268c3
Try using shorts rather than bytes for bone indices.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@238 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-10 23:21:15 +00:00
Andrzej Kapolka
8a0168760f
Much work to reconfigure shaders automatically based on the model's
...
current JME state set.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@237 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-10 20:35:27 +00:00
Andrzej Kapolka
1d8f04c43a
Prepend the #version directive before compiling the shader.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@236 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-10 01:31:42 +00:00
Andrzej Kapolka
e5db96b963
Ignore cull mode when we're generating frames to morph between.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@235 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-10 01:07:54 +00:00
Michael Bayne
2e0678877b
Use the hacky PerfTimer if available and fall back to the NanoTimer if we're
...
running in a sandbox.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@234 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-09 21:53:42 +00:00
Andrzej Kapolka
45df6d814b
Use VBOs for vertices, indices when using shaders; multiply vertices by
...
weights even if we only have one weight per vertex.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@232 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-09 19:51:32 +00:00
Michael Bayne
0024a02067
Wow, the media framework gets into a bad way if it's forced to use the
...
inaccurate System.currentTimeMillis() timer. Fortuately Sun introduced
System.nanoTime() in 1.5 which provides civilized timing information, so we can
use that instead of sun.misc.Perf which is unavailable in an applet sandbox. We
will need to go in and try to cope as best we can with currentTimeMillis() if
we want to support unsigned play in JDK 1.4 or earlier. We'll do that later.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@231 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-09 19:22:10 +00:00
Andrzej Kapolka
ef35b37648
We need to create a new array when we're *not* using shaders.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@230 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-08 01:56:53 +00:00
Andrzej Kapolka
742dc30f9e
Basic support for skinning with GLSL shaders. Still need to work out
...
how to handle different lighting arrangements and complex materials
(e.g., the metal effect for the Iron Plate).
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@229 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-08 01:50:07 +00:00
Mike Thomas
8a2e67831e
Also need to cope with non-component _root in BackFrameManager
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@228 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-04 23:14:26 +00:00
Michael Bayne
2c6fdf5d94
Cope if our ManagedRoot is not a component.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@227 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-04 23:08:08 +00:00
Andrzej Kapolka
3401bbf3bf
Don't skin what you can't see.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@226 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-04 01:25:40 +00:00
Andrzej Kapolka
bb54ec1888
Optimize vertex order for cache usage and use a better data structure to
...
(re)index vertices.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@224 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-04 00:39:54 +00:00
Michael Bayne
095c718244
Render to the applet instead of its parent window since that doesn't work.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@223 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-03 22:56:29 +00:00
Michael Bayne
ab6252cee7
Widened. Added getMirage(String).
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@222 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-03 21:13:32 +00:00
Andrzej Kapolka
277b62bd52
Don't merge meshes where, in any animation, one is visible and the other
...
isn't.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@221 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-02 18:19:09 +00:00
Andrzej Kapolka
072926f814
Merge meshes in animated models by finding ones that maintain the same
...
relative position throughout all animations. Also, don't include
transforms in the animations for nodes that never move.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@218 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-05-01 23:36:23 +00:00
Andrzej Kapolka
250670e699
Default to using S3TC texture compression.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@215 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-04-27 20:48:48 +00:00
Andrzej Kapolka
488d47262b
Where possible, merge meshes with identical attributes.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@201 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-04-18 21:06:08 +00:00
Dave Hoover
4b933b4379
Keyword substition.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@188 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-04-07 00:22:24 +00:00
Jonathan Le Plastrier
a6fca4c25e
Kill off the .cvsignore files.
...
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@187 ed5b42cb-e716-0410-a449-f6a68f950b19
2007-04-06 23:09:28 +00:00