ed_mack at September 17th, 2004 13:53 — #1
Description From over the previous summer, my first real attempt at a 3dMax .3ds file importer and renderer, with a silly cloud renderer. Simply it's a skybox, with a large amount of billboarded cloud sprites, and some Max objects loaded with a oneliner.
From a technical point of view, it is of course pitiful, but hopefully you can cast your mind back to those days when you were simply pleased when your tga image loading code worked hehe. Probably the hardest bit of it all is my castle which I painstakingly placed through moving walls and towers untill it all sitted on the right place.
Anyway, show and tell!
anubis at September 17th, 2004 14:08 — #2
looks good... except for those gaps in the sky. that needs to be fixed. otherwise... neat
nomadrock at September 18th, 2004 03:12 — #3
You can fix the seams by fixing your texture options. It has to do with texture blending and whether or not it can go over the [0,1] boundaries. I forget now, but I bet you are good enough to look it up.
ed_mack at September 18th, 2004 04:38 — #4
I read about the border problem on Flipcode, but forgot completely about it. Previous to that I scrutinised my tga loading code sure there was a problem with it
I think I shall look it up..
dk2 at September 18th, 2004 13:20 — #5
you need to use GL_CLAMP_TO_EDGE to get rid of the seams:
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE);
If you have old ogl headers, it might not be defined, but here's its #define:
#define GL_CLAMP_TO_EDGE 0x812F
ed_mack at September 18th, 2004 14:17 — #6
Aww, it worked! Thank you so much!
Here's the same engine running a navier stokes water solver (to low res) and a real-time deformable landscape (there's a bug in the height interpolation, I know). And, no seams! Thank you! That's annoyed me for a long time.
nezbie at September 19th, 2004 11:34 — #7
Looking pretty good there.
Some things you might want to try
-See if you can add detail/multitexturing for the landscape, as that makes a lot of difference in scene quality. It's a lot easier than it sounds.
-smooth shading for water
Some triangle strips in your reflection rendering (are you using 2 pass rendering over an axis?) arn't shown.
Are you loading/generating your landscape? If you post your interpolation code, I'm sure I could help.
ed_mack at September 19th, 2004 23:48 — #8
It's old code, I'm not going to improve anymore. But thanks for the suggestions