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.


Messages - meinfilter

Pages: [1]
1
Projects / Imperio - Galaxy-wide strategy
« on: July 13, 2006, 05:27:14 pm »
Sorry I didn't post before.

At last, I have finished my project. Finally I haven't used jPCT as the API for 3D graphics, primarily because of lack of time. I sticked with IDX3D, and concentrated in other non-3D aspects of the project. In fact, I believe jPCT would have been a better choice than IDX3D, and I would recommend it.

To solve the problem of displaying the names of the planets, I tried the brute force solution, and it worked fine with little impact on performance. I make a postprocess: check every pixel of every rendered 2D frame, looking for 3D objects. I do this thanks to a function that IDX3D offers: scene.identifyObjectAt(x,y). When every pixel has been checked, I blit the name of every planet that has a minimum number of pixels displayed.

I don't know if this is such a horrible solution as I thought at first, but it works fine for my application.

Thanks for the tips you provided, it was significant to help me with the project.

Here is an image of the result:
[img=http://img71.imageshack.us/img71/2421/vtacticaphpconnombres5ws.th.png]

Edit: I forgot to say that finally I didn't draw distant stars. It wasn't a compulsory requirement, and I thought that leaving the background black would improve readability.

2
Projects / Imperio - Galaxy-wide strategy
« on: December 07, 2005, 12:19:38 pm »
Quote from: "raft"
you can almost forget about texture based strings, they arent readable. have a look at the screenshots at karga thread

for skybox, instead of using a huge sphere i store a small sphere in a seperate world where the camera is always located at origin. than i simply render both of my worlds (the skybox one and the regular one) to same frame buffer one after another


OK, I've seen those screenshots. The second balloons you use, the blitted ones, do they hide behind objects? How did you do it if they do? I can't figure how to do it if they are not 3D objects in the scene.

About the skybox, thanks for the idea, I will try it.

PD: I'm still working in other tasks and haven't yet resumed 3D graphics work.

3
Projects / Imperio - Galaxy-wide strategy
« on: November 29, 2005, 10:23:32 am »
Quote from: "EgonOlsen"
Drawing points would still require a zbuffer read/compare. Maybe the best (or at least a reasonable) solution is to use actual objects placed on a sphere instead of the textured sphere. They can be stars, distant galaxies etc...that way, you are saving fillrate and are getting a higher flexibility. At least until you insist on hundreds of stars in the background, which i think you don't.


Very well, thank you again for your help. With it, now I see things less dark ;)

Right now I'm busy with other pressing tasks of my project. When I resume the 3D displaying task and have something to be shown, I will post here again to show you. It may be more than a month from now, but I'll be back :)

4
Projects / Imperio - Galaxy-wide strategy
« on: November 25, 2005, 09:56:00 am »
Quote from: "EgonOlsen"
Quote from: "meinfilter"

About drawing distant stars: they are just for decoration; the camera can move around, but I would set a limited volume in which it can do it, so these distant stars would remain always distant.

Then a skybox or -sphere should be sufficient. But that eats up your fill rate for the software renderer. Are you planning to use soft- or hardware rendering?


I'm planning to use mainly software rendering, because the 3D scene is showed in an applet, and I don't want to rely on the users to have the hardware library installed (that's the reason I discarded Java3D on the first stage). I supposed there was going to be a performance problem about the distant stars background, but I wonder if it could be mitigated somehow, like drawing them like points instead of using a texture, for example (and perhaps not drawing many many stars). By the way, is there a way to draw points instead of polygons? Would it be faster if there was one? To apply a texture on the sphere would be the wiser approach?

Quote from: "EgonOlsen"
I guess that you'll generate them once and use them from there on? Then you are fine to draw an image using standard Java2d stuff and upload that as a texture. If the text changes a lot, you should compose your texts from various texture parts instead (see below).


OK, once generated, the planets' name won't change, so I think I would generate an image with the characters and then use it as a texture.

Thank you indeed, EgonOlsen and Raven.

5
Projects / Imperio - Galaxy-wide strategy
« on: November 24, 2005, 08:20:49 pm »
First of all, thank you very much for such a quick reply and for your help.

About drawing distant stars: they are just for decoration; the camera can move around, but I would set a limited volume in which it can do it, so these distant stars would remain always distant.

About drawing planets' names: the grow/shrink behaviour would be OK, as it doesn't matter if distant planets' names are not readable. Would be difficult to draw characters on that billboarded quad? Something like using the Java API to draw the characters on an image and then applying the image as a texture on the billboarded quad would be the right approach?

Pages: [1]