Main Menu
Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Topics - cyberkilla

#21
Support / Compressed Textures
February 02, 2007, 02:45:27 PM
Does anyone know if the textures used in OpenGL mode are compressed?

I know that the standard images are not compressed in memory(Java2D),
but I did hear something like this on an OpenGL forum.

Its strange how Java doesnt natively use some form of RLE compression for in-memory images.

If you have a 640x480 image in memory, its a good few MB.
On the hard disk, in png format, its a few KB.
Naturally RLE isnt as powerful as the compression in pngs, but I feel my point is still valid.
#22
Support / AWTGLCanvas Speed
January 31, 2007, 03:08:39 PM
Hello, I am experimenting with billboarding, to see if there are any performance
benefits from using pure 3d, instead of rendering in 2d.
I am using the jpct implementation of awtglcanvas.

I have heard that the canvas is a lot slower than a native window.
Is this so? I can imagine some extra processing to render into awt,
but has anybody got any idea how much?

It is more than possible for me to use a native gl window, if needed, but im discouraged from this approach, because I would need to blit my menus into the
framebuffer.

I also use scrollpanes, and skinned buttons via SkinLF.jar.

This is merely a test. A test to evaluate the performance boost, if any, when using  pure 3d, and not using trickery to put 3d onto 2d.

Thanks in advance, for any help:)
#23
Feedback / jPCT
January 31, 2007, 01:55:52 PM
Egon, I use this piece of code to add an entire stack trace to the logs.

Perhaps you can find use for it in the official logger.


public static String getStackTrace(Throwable aThrowable)
{
   final Writer result           = new StringWriter();
   final PrintWriter printWriter = new PrintWriter(result);
   
   aThrowable.printStackTrace(printWriter);
   return result.toString();
}

To use this, I have a Logger.addError(Throwable e) method.
It just turns the stack trace into a string.

I cannot use the official logger, because I already had my own.


It is very useful for me, so I thought I'd share it.
#24
Feedback / Learn 3D Concepts! Tutorials!
January 23, 2007, 07:09:56 PM
This website is a fantastic tutorial!

It explains zbuffering, octrees, backface culling, uv normals,
perspective correction, world/camera coorinate systems,
matrices, texture mapping, and so much more!

It touches on almost everything, and provides examples, and/or links to other
sources.

http://gamecode.tripod.com/tut/

Check it out! Seriously, its the easiest to grasp one I've found yet.

It just makes the fact that this engine works so well, even more of a wonder;)

--------------------------
By the way, somehow I am able to make this a sticky. I was under the impression only mods could do this :twisted:
#25
Support / Transparent Backbuffers
January 23, 2007, 06:32:07 PM
Egon, is it possible to have a quick method/constructor parameter,
that would allow the use of a BITMASK backbuffer, when possible?

I know this isn't used on the 1.1vm, but on the later sun vm's, it is just a simple
change of a flag from OPAQUE to BITMASK.

It don't know how it all works, but, is is possible to set up such an option?

That way, I could pass a transparent color to clear the framebuffer before render.
Then, I would not have to have the additional step of drawing to another image, to manually set the background to transparent.
It is a difference of 25fps, shockingly.

This would be a great help to anyone trying to superimpose rendered models
into a 2d environment.

Perhaps, if its possible, the next version of Jpct could have this functionality?

My appologies, I realise I am asking a lot of questions:) I just want to squeeze as much power out of the engine as possible.
#26
Support / Special Effects.
January 22, 2007, 02:35:25 PM
Yes, im back again, asking strange questions:).

I was thinking about how I could implement effects into my game.

What I mean by this is:

Player fires gun  -  >  bullet comes out:).
Player casts a spell  -  >  magical sphere encapsulates them.

I suppose this is possible using 2d animation, but, has anyone got any opinions in 3d?

I can use 3d projectiles with ease right now, so bullets, etc, can be 3d.
With forcefields, etc, has anyone got any tricks?

Perhaps a large sphere, with a transparency set, and a plasma-like texture?
If i rotated it along a few axis' it might look good.

Maybe fire would work as a fast rotating sphere with texture only at the bottom, where the players feet would be?

Any ideas are very welcome;)
#27
Feedback / Wavefront OBJ Format
January 20, 2007, 12:15:50 PM
I wonder if anyone has planned a loader for this?
----
It seems to be the ONLY format Blender exports properly!
I am shocked to find out that:

MD2 Models export as a solid block of disortion, but with correct UV Coords!

3DS Models export as a correct model, but entirely destroyed UV Coords,
and no reference to the texture!

ASC is not supported, not even a plugin can be found.

JAW is naturally not supported.
----
It is sickening that is doesn't work. I like these OBJ formats more and more.
I would like to build one myself eventually, but I have only minimal free time right now.

If anyone has any ideas about a workaround, I'd appreciate it.
Regardless of any help, I will be making an OBJ loader at some point:)
----
How on earth could they make a faulty MD2 importer? The format is so simple, there are even tutorials!

--------
I will post any links I can find that are interesting...
http://www.martinreddy.net/gfx/3d/OBJ.spec
http://www.robthebloke.org/source/obj.html
http://www.csit.fsu.edu/~burkardt/data/obj/obj.html
--------
That last link has some example import/export source code,
and many small examples of models.
Look how simple it looks...

# cube.obj
#

g cube

v  0.0  0.0  0.0
v  0.0  0.0  1.0
v  0.0  1.0  0.0
v  0.0  1.0  1.0
v  1.0  0.0  0.0
v  1.0  0.0  1.0
v  1.0  1.0  0.0
v  1.0  1.0  1.0

vn  0.0  0.0  1.0
vn  0.0  0.0 -1.0
vn  0.0  1.0  0.0
vn  0.0 -1.0  0.0
vn  1.0  0.0  0.0
vn -1.0  0.0  0.0

f  1//2  7//2  5//2
f  1//2  3//2  7//2
f  1//6  4//6  3//6
f  1//6  2//6  4//6
f  3//3  8//3  7//3
f  3//3  4//3  8//3
f  5//5  7//5  8//5
f  5//5  8//5  6//5
f  1//4  5//4  6//4
f  1//4  6//4  2//4
f  2//1  6//1  8//1
f  2//1  8//1  4//1
#28
Support / Changing Display Mode
January 11, 2007, 07:02:04 PM
Egon, I was wondering, how did you change the display mode on your game project? I cant remember its name:)

You see, I am using the standard GraphicsDevice/setDisplayMode method.
But it doesnt work reliably in Linux because of strange problems related to the enumeration of available modes.

HOWEVER, your game CAN change the display mode in both linux and windows for me:O.

Is there any chance you can tell me how you did it?

Thanks again :wink:
#29
Support / Bounding Box
January 11, 2007, 04:15:15 AM
Hey:)

Does the bounding box( which tells me not to call it too much ), change values
as a sequence of key frame animation is played out?

I would assume so, because my "dirty rectangle" clipping doesn't cover the avatar when he lifts his arms:).

If this is so, how can I make sure I have the right bounding box, without a major speed slowdown? I would appreciate any help on this;).
#30
Support / Increasing Quality in Software Mode
December 16, 2006, 02:49:50 AM
Hey I know it might be because im rendering small,
but I seem to get a lot of diffusion.

Is there some way of making the shading a bit cleaner, without
having to resort to scaling a larger render?
Im really trying to keep my rendering costs down.

It looks beautiful if I render at 400px by 400px, then scale down to 200x200,
even at the lowest scaling quality(linear, i imagine).
However, i dont want to loose any speed.

Any ideas?
#31
Projects / FutureRP
December 12, 2006, 08:48:18 PM
Hello everyone, I just thought i'd start making updates here,
now that I have some screenshots.
The tiles im using are borrowed, but I have some professional tiles being
drawn for me over the next few weeks:)








I am having trouble with smoothly ascending stairs in isometric,
I am having trouble with swapping clothing/weapons on 3d models.


If ANYONE has ANY information on this, I will quickly become your best friend.
My deadline for a public beta test, with these two issues fixed, is the 25th of this month:).
#32
Support / 2D Isometric Maps With 3D Models...
December 12, 2006, 08:40:52 PM
Hello everyone! I have managed to achieve this quite well....

My problem is, Im not sure how it would scale in terms of speed.

Please, please do me the huge favour of reading this through. My deadline is christmas, and its drawing dangerously near:O



I currently have all tiles and objects(including npcs) in zordered linked list.
I draw the full list, including the models in the right order.

Unfortunately, I cant really cache the 3d models when its their turn to be rendered. It uses way too much memory. So, I must render them each time they are needed.

I have implemented a "dirty rectangles" system, so only the objects(tiles/npcs/etc) that intersect a dirty rectangle will be redrawn.

Here are the steps in order...IGNORING DIRTY RECTS:)

-Iterate through map objects, painting each at the right location...
-If its a tile, then paint a tile...
-If its an avatar(npc/player), then render model to 200x200 framebuffer,
with a MAGENTA background. Create new image with MAGENTA set to TRANSPARENT. Paint onto main backbuffer.


Now, that works. It really does. The problem is it seems like a lot of trouble. Is there any ways I can improve this?

Is faster/possible to make the map into some kind of 3d object itself, dynamically?
Is it possible to set the framebuffer jpct renders onto transparent, to cut out an extra step?

Also, how on earth could I have several different avatars?
I would think a separate world for each model would work perfectly,
but is it too memory intensive?

Thank you in advance for this!


BTW: My FPS is ~80 when im not painting anything new, but drops to
~30 when im in fullscreenmode, and moving my character.
In window mode, im lucky if i get 18, and its only ONE character:(.
#33
Support / Keyframe animations from single 3ds file
December 01, 2006, 10:21:34 PM
I know this is not supported by default.
And I am not trying to force someone to implement it for me,
because people have better things to do.
My "preference" in an ideal world, is as follows...


One 3ds file for each state of my model(walk,attack,sit,etc).
Inside the 3ds file, are keyframes for the animation.

So, the walk.3ds file, has the animation for walking in.


I know you do not support this, so I have the following...


Once 3ds file for each keyframe of animation of each state.
At run time, i load all of these keyframes into an animation, and then into
a separate sequence, so all animations are in one Object3D.


It seems fair enough. Its not a huge inconvienience, provided I CAN export each keyframe as a separate 3ds file. Im using blender.



Does anyone have a better way of evading this issue?
If not, it is no big deal, but I thought it worth asking.

Thanks again.
#34
Feedback / subBlack
November 23, 2006, 09:53:25 PM
Hey Egon, do you like darker themes?

Because subBlack is very nice:) Its nothing thats needed.
I just think your logo would look so good in it!
#35
Support / Adding clothing, weapons, shields to 3d model.
November 22, 2006, 02:30:39 AM
Hello, i am in big trouble if i dont come up with a trick to do this!
Could someone give me any ideas?

In the 2d sprites, i simply superimposed them on in the paint function.


In 3d however, im stumped. I need a way to change hair, guns, boots, etc
on a generic 3d model i made.

If you help me, I will be your best friend.
It just occured to me that this would need to be done too, if i were
to move to 3d sprites!

Thanks in advance!

EDIT: Really, any ideas are great!
I prefer ONLY vertex colouring. No texturemapping if possible.

I know i can change colours of vertexes to give effect of clothing,
but things such as hoods, capes, etc, would not work like that.
#36
Hello! This is the first post ive made here:)

I have a project, in which I have a 2d isometric map,
and 3d models walking around.

I have managed to get it working!

My issue is that I cant find a decent isometric camera angle.

Another problem im having is: I am drawing in blender, and exporting
to 3DS format. If I open the 3DS file in blender, or openfx, etc,
it works properly. However, when I render it with jpct, I get a strange effect.

I looks as if the polygons are single sided. They have a colour from one angle, and not from the other.
This is fair enough, but my 3d model  has invisible pieces!
Then when you rotate it, the back of the model has the same problem,
except the faces that are invisible are the ones that were visible on the other angle!

I hope that makes sense:)


Can anyone give me a decent isometric angle, and an answer to my
single sided polygon issue?:)

Thanks again.

PS. This 3D engine is fantastic. I am going to plug it extensively on my websites if i get this sorted. It is nice that most people appear to be doing this anyway.


EDIT: Ive discovered a flag in blender to export doublesided:
http://wiki.flightgear.org/flightgear_wiki/index.php?title=Normals_and_Transparency_Tutorial
Just incase another has this issue.
Also http://www.christiancoders.com/cgi-bin/ubb-cgi/postdisplay.cgi?forum=Forum3&topic=000362
Details the use of CTRL+N in blender to make all faces "face" properly!

I hope that helps
[/i]