Terrain Algorithm: PGMM / geoMipTerrain

is PGMM work in newest Panda1.4.2? where i can get the compiled lib for 1.4.2, i don’t have VS2005 or other C++ compiler. thanks very much.

discourse.panda3d.org/viewtopic.php?t=3505, or
discourse.panda3d.org/viewtopic.php?t=3544

thank u, ynjh_jo.

Can we add pgmm to panda 1.5.0 ?

It does seem like something that should be included.

Here’s what we have to do to get it in there:

  • Insert it into the panda source tree. Choose a directory and filename for it. I suggest panda/src/grutil/pgmmTerrain or something like that.

  • Make sure it adheres to Panda3D’s coding conventions. (Ie, proper class naming, proper indentation, correct use of boilerplate like ‘get_class_type’ and all that).

  • Insert the appropriate compile commands into makepanda.

  • Write a small sample program that shows how it is used. Or, maybe instead of creating a new sample program, maybe we should discard that ugly terrain in Roaming Ralph and replace it with PGMM-terrain plus a few trees and rocks. Again, adhere to the sample program coding conventions.

  • Send me a diff.

ok so the only problem i see with this is that pro_rsoft did not want to add it yet. I hope he changes his mind when he comes back from his trip so that we all could use pgmm in our games.

Doesn’t seem like a problem for me. I’ve just came back from vacation, and have added normal calculations there. I’d like to test them a bit first so they work correctly, and I’ll try to get it ready for Panda integration.
A few questions:

  • I was just thinking, PGMM sounds a bit vague. Don’t we need a better name for the class (e.g. GeometricalMipMapper or something similar)
  • I could find the C++ coding rules, but not the one for the sample programs. Where can I find it?

Though, please remember, my schedule is quite tight. I might or might not be able to get it done before 1.5.0.

Name Suggestion:
Terrain
PandaTerrain
TerrainGMM
HightMap
HightMapDrawer
GMMTerrain

“GeometricalMipMapper” makes me think of textures mip mapper - I think maybe we should have one Abstract Terrain class of which PGMM will use - but really i dont care as long as we can use it in panda3d soon :slight_smile: like in 28 days and 9 hours. Pro i want to use your terrain for pyweek.org/6/ competition.

Josh, I’ve got it polished off and made according to the C++ coding styles… the only thing me and ThomasEgi are working on is 24+32bits heightmaps, but I don’t really care whether that makes the release or not.
*Can you tell me where the codingstyle rules are for the sample programs?
*I might be able to backwards-convert the roaming ralph terrain and turn it into a heightmap, but I think it’s too small to demonstrate PGMM’s ability and strength which is more at larger maps. How do you feel like I’d put ralph in a bigger environment?
*What do you think about a better name for PGMM?

The rules aren’t written anywhere, except one: a hard limit of 300 lines of code per sample program.

Also, try to duplicate the style - same instructions layout, same functions to display the instructions, etc.

When I was talking about stylistic coding conventions, I was more concerned about Panda3D proper.

This site has some information that can be interesting while developing terrain renderer:
“Rendering Very Large, Very Detailed Terrains”
terrain.dk/
Just wanted to let you know, maybe, you find it useful.

Thanks for the link!
I’ve visited the page and the methods there look very much like what I already use – the page also links to the actual GMM paper.

Their method is far more advanced, and documented here: terrain.dk/terrain.pdf
You can see the impressive demonstration of their method here: terrain.dk/demo.zip
It is really fast, even on the huge and very detailed terrain (the fourth fly in the demo) almost never goes under 100 fps on my old laptop.

Ok I take it that PGMM didn’t make it into 1.5?

Anyway… Could you build a new DLL for panda 1.5? Last time I built it myself it didn’t quite work right for some reason.

Also, your web site is down :frowning: Domain name expired. I can host files for you if you want though, mail me at bjarnia?gmail.com

i cant really agree with that statement. they both use pretty much the same basic principle, based on geomipmapping with slight changes.

they have some slight differences in detail but they are technically not that much different. both should be able to produce simmilar outputs.
since both sources, pgmm and your vlterrain demo are given you could port it to make it usable with panda if you like.

talking about pgmm. it has a few more advantages which are not yet visible. since pgmm allows to horizontally displace vertices without messing up.
also. keep in mind that pgmm is still in development.

I second bjarnia’s request. If someone could compile a PGMM version for 1.5 that would be beautiful.

Also, I haven’t been following PGMM (or really anything Panda3d) recently- has Treeform’s image blending been added yet?

Later.

We want pgmm in the distribution!

Will try to do it before easter.

still awaiting eagerly! :slight_smile:

is there anyone else that can build a preliminary version untill pro-rsoft has time? I’m using PGMM in a school project that is due in a week, and I would really like being able to use some of the new shader features :astonished: