Capabilities of Panda?

Wavelets is a form of lossy compression. Its similar to Fourrier analysis.

Essentially, any waveform can be constructed as an equation (bit rusty, so I might be pi/2 out or something here):

y = a[0] + a[1] * cos( theta ) + a[2] * cos (2 * theta) + a[3] * cos( 3 * theta )

… as long as you add in an infinite number of terms.

With a small finite number of terms, what you get resembles the input, but it can take up a lot less data. Obviously its not lossless: the compressed version isnt quite the same as the original.

You can create wavelets using anything really, doesnt have to be sine waves, could be square waves, sawtooth waves. This guy cs.ucr.edu/~eamonn/ has tried several different types for time series data compression / matching, and found that using a square wave works just as well as sine waves, for pattern matching, but runs much much faster.

What you were doing sounds similar to what I’m suggesting, because you’re taking squares from a grid and compressing them, albeit losslessly. I guess the bit where I’m trying to add value is in using a lossy compression, and getting a progressively more “blurry” image as the distance from one’s avatar increases?

I guess the issues I have are:

  • to what extent does what I’m proposing correspond to what has been done before (answer: somewhat)
  • how good a representation does wavelets make of the source, ie how many terms does one need to take? (answer: not sure; need to play around probably and get a feel for this)
  • what methods are there for generating wavelets? I’m thinking maybe FFTW can do this? A Fourrier Analysis app is possibly sufficient? And I guess it can cope with 2D fourrier analysis, since its designed for pictures and stuff? Perhaps there are other applications out there more suited for wavelet decomposition?
  • blending between the different squares. Obviously, if I have a 256m x 256m square independently compressed, in a very lossy way, compared to the 1024m x 1024 m its sitting in, there could be discrepencies along their border, so probably need some sortof blending?
  • other issues, as yet unknown

What do you think?

Hugh

I think you’re working too hard. :slight_smile:

That’s only half-joking. Writing an online persistent world is a huge project. The worldforge guys have been at it for years, and they don’t have anything that big running. It took me two and a half years full-time to implement the core of ATITD - and I suspect you can’t work on this full-time.

Which is why I think you need to budget your time very carefully. I think it is possible for you to create an interesting online world, but you have to be ready to omit nonessential features.

In this particular case, I think that supporting modems is a nonessential feature. I wouldn’t spend too much effort on compressing these patches. I’d call zlib and leave it at that.

The worldforge guys have been at it for years, and they don’t have anything that big running.

Heh! But I’m not worldforge :astonished:

I suspect you can’t work on this full-time.

Actually I can, but sometimes I get distracted by girls and stuff :astonished: It would however be nice to have a budget, so if you know anyone who fancies sponsoring this development, that would be incredibly cool.

Hugh

If I knew where to raise money, the panda project itself wouldn’t be unfunded. :slight_smile:

OK, back to your question. In ATITD, we made a mistake - I worked very hard to create a distant terrain horizon. But I couldn’t make the 3D model horizon as big as the terrain horizon. The result wasn’t quite right. You see what looks like empty terrain, but then as you get closer it turns into a city. It just looked wrong.

The other thing I notice is that the terrain horizon is distant, by any objective measure. For example, in many games, I can walk to the horizon in 60 seconds. In ATITD, it takes much longer. But somehow, it doesn’t look distant. I think that the perception of distance is created by visual cues like fog, haze, blur much more so than by actual scale changes.

So basically, what I’m saying is that you might want to spend some time thinking about just how far you do want to render. It’s not entirely clear.

Actually, terrains are usually made up of faces. With 4 or 3 sides.

If Panra3D can draw a single face paramatives by connecting 4 vertex points to make up a face, then boom terrain can be very possible just by setting them up using the matrix array variables.

Shoulden’t be that hard to do.

Wrt the cities-appearing things, I’ve been thinking some about this too actually.

What I’ve been thinking is: I already have level of detail for my objects, which cuts them down to 12 triangles when theyre more than a 100m or so away.

But… if an object is really far away, who cares about the triangles? We can just display them as a single point. Could be colored with the average color of that object ideally, or could be, as you are alluding to somewhat, just a blueish/greyish color.

That way, when you’re far from a city, you still see it, but its not taking up hideous amount of rendering resources.

Now, obviously when you get really far away, if youve got a city of 15,000 objects, even if they’re just points each, its kindof silly to render all 15,000 points, so what we can do is simply just start sampling them randomly. For example, we might just take every 100th object and render it as a point.

We’re not trying to render the city perfectly; we dont need to since its only taking up maybe 50 x 50 pixels on our screen. We just want to give a little bit of information that there is actually something there, maybe a hint of how it looks in sillhouette.

How does that sound?

Hugh

The more I research Panda and what its capable of the more questions I seem to have. :slight_smile:

I’m going to bet Disney is making changes to Panda to allow stuff like panoramic terrains down-the-road, especially for their upcoming Pirates game.

It seems most of the ideas for games I have involve a character crossing large terrains and not self-contained models that encompass the entire world which seems to be most of what is being created currently with Panda.

Sure would be nice to be a student at the ETC and ask all my questions at once. But hey, we are getting our questions answered for free here so I guess I should be happy with that :slight_smile:

Hello

I am the project founder of Daimonin (http://www.daimonin.net), a open source mmorpg.

I stumbled over Panda3D in the search of a good render & base system
for our coming 3d client.

Is ATITD related to panda3d? It is used as engine there or parts?
Just wonder. Its a Great game.

I am also work some years now on the core of Daimonin. Even i got the
start source from crossfire (mainly to have a good start and i wanted
from the source base something like cf’s server) there was alot work.

The interesting point is, that our server (who is in C) used a python
scripting plugin that we changed to LUA earlier this year.

The difference between both language as embedded script language
is extremly huge. There is nearly no area lua has not big advantages.
Its really a great language. So extremly easy & logical. It would be
great success if it even would become a full standalone script
language on the same level as python for example.

But as embedded its really the #1. I wrote my first scripts in the lua
just by looking at the template script and thinking “now i want a function
with paramter and return - when i look at this other source how would
it be logical to do?”. I wrote it down and … it worked out of the box!
Every other member of our mapers or developer had the same
experience.

But the more interesting part is speed & performance. In the BEST CASE
python is 2.5 times slower as lua. In worst case, it will be up to 4-5 times.
We can say it (and everyone can test it) because we can checkout from
our CVS a server version with lua plugin & python plugin script engine.
And do some real “reality” profiler runs. Its really amazing, how
superior lua is in the embedded area.

We want use C++ for our 3d client but i really like the python interface
of panda3d. That will allow fast testing and prototyping not to mention
the easy way to create tools and stuff which is not less important.

I tried to use in Daimonin btw. the best language for the specific
application. Our server is C, the script langauge lua, the editor
is in Java and the 3d client will be C++.

It shows up more and more that this was and is a very good decision.

Daimonin is “native” cross-platform. The server compiles with VC6-7 under windows and with gcc under linux. Same of the 2d client.
Also mac works fine, we just miss a developer who checks the
make files.

Well, to our language zoo, python will for sure add fine as 3d tool lib.

Just a note: Don’t get confused by the simple 2d client and its tile
based movement. I had started the project mainly as “educational”
project to myself and i wanted a easy frontend. My main reason
was to learn how the server works and there the most work has
going in. Its a somewhat powerful & unique system. For the 3d
i will improve it to have a ultima online / Ragnarok like isometric/
orthographic view with softscrolling/pixelwise movement. I am
just preparing after the next beta release the new protocols.

The 2d client is build out of “public avaible” graphics. From nethack,
angband, free tiles and free pictures. Only very few are drawn native
for it. Its alot easier to find good 3d models (and manipulate them)
as in 2d. The lake in good looking monster animations (in 2d) was
the reason i don’t added softscrolling earlier. Not to mention the
huge graphic work needed for customizable & animated player
chars…

Just as a general question: How hard/easy is it to setup panda3d in a
orthographic view?