gbadev.org forum archive

This is a read-only mirror of the content originally found on forum.gbadev.org (now offline), salvaged from Wayback machine copies. A new forum can be found here.

DS development > GDC DS-papers

#139784 - syncope - Mon Sep 10, 2007 3:46 am

Huh, didn't make it this year but...suprisingly the GDC07 proceedings are already publically available here.( bunch of here stuff there)

Nothing new really, but all in all I guess it makes for a friendly-written high level beginner's introduction.
Could have sworn they meant to cover dual screen 3D rendering in more detail in this one.

-The texture streaming is nice,
-Using sprites as cheap bilboard replacements for lightflares is a nice touch [mario basketball does that too no ?].
-Nice fog insights,
Speaking of which, have you seen what they are doing with fog in the Transformers DS games. Like how its smoothly receding/fading into the background. Think it looks relatively slick.
(1)
(2) - don't tell me that's just a skybox.
-and toon shading/outlines or edge marking as they refer to it explained.

*Now initially I wasn't sure wheather hotlinking was a bad idea. But these are public files, with all legally questionable content removed. Should be good to go and enjoy :)


Last edited by syncope on Sat Sep 15, 2007 8:19 pm; edited 1 time in total

#139796 - a128 - Mon Sep 10, 2007 8:14 am

Nice document...but how you simulate point lights?!

Maybe you can enable/disable the light for some polygons?!

Ok, this is possible....is this a solution for a point light?!



Or does "simulate" mean....calc you own vertex colors?!

#139910 - a128 - Tue Sep 11, 2007 1:27 pm

I use glLight(1,.........) with different directions for different models in one render frame, but of course you still have a "directional light" not a point light?!

#139915 - pas - Tue Sep 11, 2007 3:33 pm

Nice, indeed (good thing to show people that say: shut up with your underpowered DS Shit !).

BTW: Where are the Video's the Document points to ? Copyright protected ?

What do they mean with 2048 Polygons at a time ?

I thought the DS could more ? Something about 120.000 ? Or did I misunderstand something ? Could anyone link me to a good DS Fact Sheet ? Sorry for being a bit stupid, I just want to understand.

#139919 - kusma - Tue Sep 11, 2007 3:41 pm

pas wrote:
I thought the DS could more ? Something about 120.000 ? Or did I misunderstand something ?

2048 per frame at 60 FPS ~= 120.000 per second

#139924 - pas - Tue Sep 11, 2007 5:05 pm

ok, thank you !

#139959 - syncope - Wed Sep 12, 2007 1:57 am

Yes the DS (just like the Wii- what's up with that Nintendo ?) is limited in the number of vertices and hence Polygons it can display.
Better to have known limits than unpleasant suprises however.

@pas The videos are nowhere to be found, as you expected > they contain copyrighted/devkit stuff.

#139978 - a128 - Wed Sep 12, 2007 8:29 am

I have contacted Chuck Homic who held the DS GDC07 topic..and asked him about his "point light "idea....

"Simulating pointlights" using the DS hardware....is changing the direction of one light souce per frame...so model A have a different direction then model B.

And -what I missed you can change the intensity
based on the distance to the light source.

#140296 - Mumbly Juergens - Sat Sep 15, 2007 3:07 am

Some of the other titles on the GDC page you linked look interesting. I may be stupid or mental but is there a way to download them?

#140373 - syncope - Sat Sep 15, 2007 8:14 pm

huh ? oh thanks for pointing that out Mumbly.
It was meant to point to this Page
[and if that doesn't work >> simply click on 'proceedings' in the upper right corner and select 'Game Developers Conference' on the following page ;)]

#141730 - ritz - Fri Sep 28, 2007 10:12 pm

Here's my attempt at point lights (w/attenuation) using the hardware directional lights only. Dynamic works somewhat too (hold X for the light to spin around the room... move/watch the dude), but please ignore the map tiles as I've yet to modify and re-convert them for this. All the keys (except for START) and the touchscreen do stuff. Holding SELECT is just a debug key that skips swap buffers & vsync (for benchmarking things).

sonicrpg

Install as /sonicrpg/*.* in the root of your memory card.

P.S. It's best just to check out the static point light for a bit before pushing X (dynamic) because the map parts screw up :)

#141772 - xrl - Sat Sep 29, 2007 6:36 pm

Nice presentation. Are the movies available?

#141788 - M3d10n - Sun Sep 30, 2007 12:26 am

ritz wrote:
Here's my attempt at point lights (w/attenuation) using the hardware directional lights only. Dynamic works somewhat too (hold X for the light to spin around the room... move/watch the dude), but please ignore the map tiles as I've yet to modify and re-convert them for this. All the keys (except for START) and the touchscreen do stuff. Holding SELECT is just a debug key that skips swap buffers & vsync (for benchmarking things).

sonicrpg

Install as /sonicrpg/*.* in the root of your memory card.

P.S. It's best just to check out the static point light for a bit before pushing X (dynamic) because the map parts screw up :)


Looks nice. Better than some commercial games, actually. How many polygons are you using there? Btw, I noticed the framerate drops when more than one map tile is visible. Are you doing multi-pass, or is it CPU-bound?

#141794 - ritz - Sun Sep 30, 2007 2:20 am

Thanks. The entire scene including the two creatures is ~4250 triangles. Normally I would never use this many polys, but it's just for testing how much and how fast I can go. The actual vert/poly ram used is shown in that little line on the top screen (last two numbers). I use the hardware's boxtest for a lot of culling (the first two groups of numbers on that status line). I'm not sure what you mean.. multi-pass?

EDIT:

I should mention that I use NWN models (converted into a completely different format of course) for all this because I'm neither an artist nor an animator :P


Last edited by ritz on Sun Sep 30, 2007 3:12 am; edited 2 times in total

#141796 - mml - Sun Sep 30, 2007 2:53 am

Oh wow ritz, that's stunning.

#141841 - M3d10n - Sun Sep 30, 2007 8:21 pm

ritz wrote:
Thanks. The entire scene including the two creatures is ~4250 triangles. Normally I would never use this many polys, but it's just for testing how much and how fast I can go. The actual vert/poly ram used is shown in that little line on the top screen (last two numbers). I use the hardware's boxtest for a lot of culling (the first two groups of numbers on that status line). I'm not sure what you mean.. multi-pass?

EDIT:

I should mention that I use NWN models (converted into a completely different format of course) for all this because I'm neither an artist nor an animator :P


I noticed the poly counter. There are very few angles where it goes beyond the limit (I saw it go to 2400 from one angle), but strangely, I couldn't find any visual glitches when it did so. I mean, 400 missing triangles *shouldn't* go unnoticeable. Maybe its because the scene is dark or something...

#141862 - ritz - Sun Sep 30, 2007 10:05 pm

The umberhulk (the guy in the corner) is the last rendered thing and if you go over the hardware limit of 2048 you'll start to see missing pieces of him :) That's expected as I'm testing large amounts of stuff. Also, when there's that much crap going on, the framerate for this scene drops below 60 and then the DS will wait until the next vsync, effectively dropping it to 30fps instead.. that's why I have that SELECT button thing so I can still see the actual framerate for bechmarking. For fun if you wanna see a bigger hit in framerate, just add some more point lights. Edit the 'theroom.map' file to something like:
Code:
6
tin01_d01_01 0 -5.0 0.0 5.0 0 256
tin01_d01_02 0 5.0 0.0 -5.0 0 0
tin01_d01_04 0 -5.0 0.0 -5.0 0 128
tin01_d01_08 0 5.0 0.0 5.0 0 -128
c_golflesh 1 -2.5 0.0 0.2 0 -190
c_umberhulk 0 5.0 0.0 4.0 0 64
4
1 3.8 2.7 -4.0 31 0 0 0.2 0.1 0.02 0.0
1 -3.8 2.7 4.0 0 31 0 0.2 0.1 0.02 0.0
1 -3.8 2.7 -4.0 0 0 31 0.2 0.1 0.02 0.0
1 3.8 2.7 4.0 31 0 31 0.2 0.1 0.02 0.0
3 3 3 31 31 31


Actually, I'm not sure what that will look like, I just added some more lights and changed some colors/settings. This will be pretty hefty on the hardware I should thing :)

If you want just directional lights (or mix both): the first digit in the lights line is 0 or 1, directional or positional. If directional, then the next 3 floats are the direction and not it's position. After that are the R G B followed by the attenuation numbers att0, att1, att2. Range is the last one, but I have finished that yet.

#141887 - a128 - Mon Oct 01, 2007 8:53 am

ritz wrote:
I use the hardware's boxtest for a lot of culling (the first two groups of numbers on that status line).


If you are using the boxtest from libnds ..this code is broken!
So your boxtest just does not work

http://forum.gbadev.org/viewtopic.php?t=13413&highlight=boxtest

#141919 - ritz - Mon Oct 01, 2007 5:23 pm

I don't actually. I just use it in this fashion:
Code:
      GFX_BOX_TEST = VERTEX_PACK(psom->bbox[0],psom->bbox[1]);
      GFX_BOX_TEST = VERTEX_PACK(psom->bbox[2],psom->bbox[3]);
      GFX_BOX_TEST = VERTEX_PACK(psom->bbox[4],psom->bbox[5]);
      while (GFX_STATUS & 0x01) ;
      if (GFX_STATUS & 0x02) { ...

Thanks for the head's up though.

#141955 - a128 - Tue Oct 02, 2007 9:10 am

Code:

  GFX_BOX_TEST = VERTEX_PACK(x, y);
  GFX_BOX_TEST = VERTEX_PACK(z, width);
  GFX_BOX_TEST = VERTEX_PACK(height, depth);


at libnds.... width & height are in a wrong order...the above code should fix that

#142153 - keldon - Fri Oct 05, 2007 9:00 am

ritz wrote:
Install as /sonicrpg/*.* in the root of your memory card.

Okay I've tried that and still get (init FAT failed - OOPV() ). I'm using EZ flash 5 with Kingston memory.

#142307 - keldon - Mon Oct 08, 2007 12:01 am

Need some help here, how do you get the sonicrpg rom to run?

#142322 - ritz - Mon Oct 08, 2007 2:57 am

Hi keldon, sorry, was away for a few days. I'm not sure I know the answer to your question. The "init FAT failed" is the very first initializing step of the libfat library... I use an R4 card with auto-patching dldi (or something like that). You may need to patch the .nds file using dldi tools. Maybe search the forum or perhaps someone here has a similar card as you that can help.

#142329 - keldon - Mon Oct 08, 2007 8:07 am

Got it, amazing demo!!!

#142330 - ritz - Mon Oct 08, 2007 8:35 am

Glad you got it working.. and thanks :)