Terrain Source Code
Community Forums/Showcase/Terrain Source Code
| ||
I started this last year sometime but stopped working on it for various reasons. Picked it up again a few days ago and thought I may aswell release the source for it. The code is a bit of a mess, I started off knowing very little about terrain engines and botched my way through so the codes ended up a bit like a scrap book of ideas. I wouldn't expect anyone to be able to use this in a game but there should be a few ideas and methods you might be able to take from it. It's got quite a few features like colour map generation, level of detail, possible visible sets for occlusion vertex alpha for texture blending and the end result aint bad. You can see my worklog for further details here. I've inlcuded 3 examples, see example_iceworld.bb, example_tropics.bb and example_2048colourmap.bb. Theres also the corresponding files that compiled and saved those maps named complilerfor_iceworld... etc The controls are w,a,s,d or cursors to move. Hold space to fly about quickly. F1 to switch on a grid that shows you which terrain tiles are being hidden/shown. F3 to toggle PVS on or off and q for wireframe. Some screens: |
| ||
downloading now. If it looks as good as those screenshots...wow thanks :) |
| ||
I remember this from the worklogs I think :) Downloading now... I'm excited! Edit: Played around with the examples for a few minutes now... I really like how you appear to have multiple texture detail layers, so when the camera gets closer to the terrain the textures still look good. |
| ||
Me too - looks super-interesting - a bit like me. EDIT: Yehhhhhh!!! Just had a quick go on the demos - I've got to go to bed now (sniff), but this looks pretty neat stuff to me - I swear I saw a blade of grass twitch in the breeze - perhaps it was nudged by a small ant foraging? |
| ||
how did you make these terrains I see there are a few files in their did you use a specific modelling program or terrain modeller? |
| ||
Very nice, really fast. thanks for the source :) Zmatrix |
| ||
looks good - downloading now... IPete2. |
| ||
Ouaouhou ! great ! |
| ||
First i couldnt get it to work cos i was in debug mode (lol) and i compiled the "compiler" so too much time to generate. Now i got it working :) Best terrain i've seen in Blitz that is for sure. Congrats Pete Rigz! edit: oh hold on, this isn't terrain "generation" , you are using an existing height map and some colour maps. Oh too bad :( i was hoping this was being generated. Well, i can still learn about PVS and nice texturing. |
| ||
so the real question here is: how to generate those colormaps? or did you rip them off somewhere? |
| ||
Thanks for the comments all. This is terrain generation from heightmaps. It takes a heightmap - in this case ones I made in photshop with the cloud filter - and then it generates the geometry, colour maps, pvs data etc etc in code from that heightmap. All of the source for this stuff is in the sourcev12.bb file. I probably explain what it does a bit better in my worklog. |
| ||
hm. in that case....wheeee O_O i'll must have a deeper look into this...when i find time ^^ great work then, and thanks for sharing! |
| ||
cool stuff. thanks for sharing! |
| ||
That looks pretty F'Ing cool (ban me!) Why did I not see this earlier? |
| ||
Heh, noticed filax up there. New release soon eh Filax? Dang! I know I should have licensed that Shadow code! For those of you who don't know "Flynn" thats me back before Indiepath!!!! Dang Dang Dang! First 3 lines of the code ;tx Terrain builder by Peter Rigby ;Light mapper and Normal mapper by Flynn |
| ||
These are some great terrains, real nice stuff. I sure hope that someone adds this to an editor of some sort, hint hint Filax :) Would make a nice addition to TerraED. Jason. |
| ||
WOW!!! Great work.... |
| ||
An excellent terrain editor that could be used along with this: http://www.blitzbasic.com/Community/posts.php?topic=52132 |
| ||
Nice work Pete. Any plans to make this more general purpose? (Standalone editor? Payable?) |
| ||
just want to inform you, that i've started an freeware opensource editor for this. Do you want to know more? :) |
| ||
Cool, best of luck with that Ojay, it's cool to see some good use out of it. I'll try my best to answer any questions you might have about the "inner workings" John, thanks for the comment, I'm finished with this system now so I doubt I'll add anything more to it. |
| ||
Link won't work...can someone mirror this or can you look into hosting it from another place Pete? Thanks. |
| ||
if it is ok, i would mirror it on my server: http://ftp.eqil.de/txLandScapes.rar (~21MB, i've included executables for the 3 samples for the 'not 3D blitzers' :) ) |
| ||
Go for it Ojay - nice one! |
| ||
Cheers Ojay, my webhost was experiencing a temporary hitch, it should be back up again now. |
| ||
Cool I see my vector lib in there. =D This is some very cool work. It's perfect for cruising over in a plane! Great work Pete. |
| ||
Looks very good; I'll have to check this out. |
| ||
These are definately the best looking terrains by far that I have seen produced with Blitz3D. Jason. |
| ||
thx |
| ||
Hi :) Don't panic Indiepath i'm working on :) |
| ||
wow... super impressive!!! --Mike |
| ||
impressive :] |
| ||
Hi All The download link for this http://82.110.105.17/peterigz.co.uk/files/txLandScapes.zip is broken. Is anybody aware of anywhere else it's available? Cheers GrumpyOldMan |
| ||
Hello, I had to take the file down because of bandwidth limits, I'd uplaod again but haven't the file at hand atm, however Ojay a few posts above kindly mirrored it and that link still appears to work. |
| ||
Yeah, I can see a nice military-style shooter out of this. Thanks for the release of this! Did you get any aid from TerraGen or L3DT per chance, or any tools like that, or was this stand alone with standard Photoshop, and B3D's built-in tool for terrain? |
| ||
Someone was making a terrain editor for this...but I think they didn't have the ability to finish it. Was hoping to it would see the light. =( |