Kramsta by Damage

2nd in the Xenium 2022 PC Demo Competition

Code: @miklesz (Mikołaj Leszczuk), Msx: Dan (Dan Lulkowski), Gfx: Sitek (Marcin Sobczyk)

Kramsta is not just a PC demo, but a multiplatform demo for PC (Windows/Linux) and Mac, made with Python and Panda3D. We developed it on macOS and tested it quite extensively on Windows. It also runs on Linux, although testing on this platform was very limited.

Back on Scene after 27 long drunken years!
No hair, less liver, more fat, still elite :slight_smile:

10 Likes

Very nice work with nice camera effects (and nostalgia)!

I am really glad to see a whole demo made with Panda3D (as mentionned in the end of demo credits, python would probably not be the “first choice” in the demoscene :slight_smile: )

Would you mind at some point sharing some technical aspects of the demo (performance tweakings, code size reduction (if any), assets creation…)?

Waiting for the next year demo :slight_smile: !

1 Like

Thank you for your words of appreciation.
In fact, Python is a rare choice for demoscene. But I figured, if I know Python pretty well, why not?
Of course, I am happy to share the technical details.
Performance tweakings? It wasn’t much. Interestingly, the slowdowns are usually not due to point-cloud rendering, but rather slow particles system that I used. Some built-in GPUs also have problems with shader switching in this demo. There are also occasional cuts when reparenting new points-clouds to render (these point-clouds have millions of points!).
Code size reduction? In fact, there was no such thing. The competition rules did not limit the file sizes. I will say more: even sometimes, working under the pressure of time, I did not focus on some sophisticated functions, loops, not to mention object-oriented programming - the code is terrible in places, because I stopped caring from a certain point to make it beautiful. For the same reason, if anyone wants, I can give access to my GitHub, where I put the sources, but I didn’t make it public, because normally I just feel a little ashamed for such ugly code.
Assets creation? In general, I recommend going to:
https://files.scene.org/browse/parties/2022/xenium22/demo_pc/
There are demo builds (files: “damage_kramsta …”) for macOS, Linux and Windows for download. After unpacking, it is easy to see the assets. There is a lot of it, the entire demo takes about 1 GB of which as much as 900 MB are .bam files with point-clouds. These are LIDAR scans. I created the vast majority of them myself with the help of the iPhone 12 Pro (the rest was done by a colleague using the iPad).
If something else interests you - please ask.
And I’m getting down to work on the demo for 2023. :slight_smile: Probably I will ask some strange questions on the forum again, the inquisitive will be able to guess a bit what we are working on.

2 Likes

Thanks so much for your comments and proposals.

Demos are my main interest for using P3D. My neverending :slight_smile: project is to develop a ‘demomaker’ tool for my own -educational- purpose - DemoMaker: non interactive animations creation tool - Showcase - Panda3D

Please let us know how you progress on your next demo!

1 Like

Thank you for the link to the DemoMaker. I definitely need to look at this project.
At the same time, my interests are rather not creating demos with the help of demomakers, but rather independent programming. Nevertheless, such a demomaker can be a source of inspiration for me.
Maybe I’ll come back with some questions, also about code examples, how was something done? By the way, if you were interested in something from the code of my demo “Kramsta”, I would like to share it (although I note that at the end I wrote this code under time pressure and unfortunately some parts of it are written terribly lame).

Most (best?) demos seem to be written without any demomaking tool (apart for Farbrausch?), due to a probable lack of flexibility of these tools (and time required to design them). I am doing it only for my personal learning and if it could be a kind of showcase of what P3D can eventually do or a source of learning, then I am fine!

Sure, do not hesitate, I’ll be more than happy to share code and exchange ideas. If you are interested, I’ll can send you the whole code (Python and a little bit of C++).

Be assured: mine is probably much much worse…even with no time pressure :slight_smile:

1 Like

Oh yeah you’re right, but it’s worth noting that Farbrausch made demo makers for their own needs and just published them afterwards:

Notch is a similar concept in some way:

It was created by the people of CNCD and Fairlight. And although Notch is not intended to be strictly a demo maker, people use it to create demos. At the same time, again, the best demos made on Notch are by the creators of Notch themselves, i.e. people from CNCD and Fairlight.
But I do not know if by any chance we deviate too far from the subject of Panda3D.
So, since you are declaring your help, have no mercy! I will be going through what your demo-maker can create and I will probably bother you with questions periodically! :stuck_out_tongue:
At first, I was interested in your volumetric clouds. I have an idea to “fly” over the city drowning in clouds in the next demo. The city itself is not a problem of course, but I have no idea how to make realistic looking clouds. Can you give me a hint?

Thanks for your answer and sorry for my delay!

There are not volumetric clouds (this is is something I’ll probably need to work on at a later stage, when I’ll integrate an environment “demo object” in DemoMaker) but only:

  • High quality skybox

  • Particle system used to generate the steam. This particle system is not the P3D standard one but a GPU particle system mainly based on the Flavio’s code (thanks to him!): example of shader-based particles by cflavio · Pull Request #476 · panda3d/panda3d · GitHub

    I added some features on top on Flavio’s code: emitter shape, geometry shader, some rotating effect
    on particle… (old code so I don’t remember right now all what was added but these are the main
    features)
    Of course, for particle systems, everything relies on base texture and parameters. For the base
    texture, I simply use the standard P3D one provided in the SDK.

For the parameters, here is a view on the options used by DemoMaker:

To put it in a nutshell: nothing highly advanced but a combination of nice features initially developped by community members :slight_smile:

Should you want a piece of code (from wezu) demonstrating procedurally generated clouds on a skydome, you can refer to: wezu/koparka: A heightmap and/or level editor for Panda3D (github.com)

If you don’t mean to have the view fly through the clouds, then perhaps you might be able to arrange something with a flat mesh, its vertices animated via Perlin-noise, and a two-pass depth-comparison to determine its opacity, the latter perhaps further perturbed by more Perlin-noise?

I’ve also seen 3D Perlin noise applied to multiple layers of quads, which can be quite effective–but at the cost of a fair bit of overdraw, I fear.

1 Like