The Future's Length

Just wanting to see what i can get from upbge. I really feel that UPBGE is Source engine level from 2005

450K vertex in the scene, 960 * 720 , just a sun and 2 hemi .

Sorry for the camera job

2 Likes

Yeah, what exactly is it that makes modern (indie) games look so good?
Is it only the PBR workflow and global illumination? Or what is lacking in upbge?

its hard to compare at this point since BGE/UPBGE are out of league since a while. But i could say its not that important after all … When you see old commercial games maps, they are hammered under different light sources and it works well

UPBGE can cope with some fancy shader tech like PBR and SSR, as long as basic things such as shadows and lighting are not handl correctly , UPBGE will be limited to display a PBR ball rocking on on a SSR plane and at the end of the day, the result will be just look awkward (a bit like pasting a photo-realistic object on a cartoonish background) . It hurts eyes

No work has been done in compiling and optimizing all the postprocessing filters in a single pipeline. You can add a bunch of 2d filters with over-lapping and run them all en mass, a solution has to be found to improve the performance. This is Tesseract (Cube2 engine with a serious rendering pipeline) in 2014. Looks ok for me. Why would we need eevee if we have this ?

Source engine in 2005

So to face the shortages of UPBGE , one have to play tricky things . Problem is that you have to be in a pre-defined setting to use a specific trick

  • vertex-parent the sun to the character ? … ok, until you enter a building
  • switch-on lights only present on the camera ? … nice, you will see your character’s feet in total dark
  • use 2 hemis to fake global illumination ? … how can we hide that monster that is supposed to jump out of nowhere ?
  • lets bake ! smart, but let forget all dynamic light sources
  • … etc … it’s a looping problem

So it’s all about setting little tricks that are ok if you consider that a game is limited to a specific configuration … ie : parent a gun on a camera and walk around on a plane which most people do . Or, you can go with materials and make a lot of puzzling to assemble it all in a same box : constraints, performance, issues and expectations

At the end of the day, the most wise would be just to showcase upbge 0.25 in a proof of concept demo displaying its current capabilities and limitations. For example, i could state that i go for a single 4096 sun
and bake all the other light source in 4096 texture … but then in the game runs at 23fps in full hd

Ofc, i would be very glad that UPBGE devs would ‘simply’ try to improve lighting performance of UPBGE 0.25 and bring it to top maturity instead of investing energies in trying to catch up i don’t-know-what in a forward rush. But maybe i’m wrong, maybe upbge eevee is going through a bottle-neck now and it gonna be fine after. But if UPBGE 0.25 struggles to display 20 light sources, i wouldn’t trade even less performance just for the sake of using a “modern” rendering engine

1 Like

one can use a mini-vertex-parented-shadows-only sun for each character and big sun for all the map

— with only environment lighting ----

no textures

add diffuse texture

add baked AO texture

add baked Sun Light texture (and its shadows)

1 Like

The problem with BGE/UPBGE lights it’s that, whenever you add a light, the code to shade that light is added to the shaders of every material, so every light is shaded all of the time, even when hidden or in a hidden layer: the lamp data is zeroed, so it may appear that a light is off, but is actually being shaded with black color. The shaders have a static code for shading, and this is noticeable when you add multiple instances of a lamp, only one is shaded because there’s code for only one instance of that lamp.
You may have noticed in Tesseract how point lights have a sphere falloff, like most game engines, this allows to stop shading lights whose illumination radius is outside the camera frustum, as well as culling them based on the distance from the camera.
I’ve always liked the Tesseract engine, the GI looks really nice, but even without it, I think shadows for point lights and cascaded shadows for the sun add to greater ‘realism’ that, say, PBR. For me, lack of shadows is more noticeable than phong highlights.

1 Like

I’ve been told that to really switch off a light during game, you need to python the diffuse and specular off (so set to 0) . I tested it and yes, it works . I think that UPBGE users need to come to a point that they have to conceive their levels having in mind that only a limited number of lights → so this implies so game orientation to begin with : walking on a desert planet is ok , but walking inside an open-space office building starts to be tricky… I made that test some time ago : you can use many lamp data’s to program your character diffuse and emit node material channels without having to have your lights on (so diffuse and specular set to 0) and it works pretty fast … But inside the node setup i had to take the biggest light source source to set my material by making some node hubs

Here below, only 2 hemi’s are lightening the while scene thx to baking … I think Upbge is ok if you make some game with everything mild lighting and cheating on details . Just accepting you wouldn’t get things dynamic


full HD , 450K vertex , 2 Hemi lighting only , 1 mini sun parented to the character for shadows only

960x720 (the screen-recorder eats a lot)

as you can see, something has to be done to avoid having the character sun shadow inside the building . A trick would be to have the ground in the building being a separate material (even tough sharing same textures) that will not receive any shadows , the same way, only some parts of the building outside would would have materials that cast shadows

all baked . 210 light source

How are you applying the lightmaps? With nodes, you could multiply the shadows with the lightmaps.

the shadows of the character’s sun * the lightmap of the materials inside the building ?

I will try even if i came to a more pragmatic solution ( a single vertex parented sun ) . But why “multiply” ? It’s about canceling a shadow . White/1 * Black/0 = Black/0 , no ? (supposing the shadow output is black)

Multiply the shadows with the materials outside the building; assuming the sun is set to Only shadows with diffuse and specular disabled, the materials inside the building won’t get any shadows.
Or with a sun of 4096 in size, but set to static and ‘This layer only’ with the static geometry in a layer, and dynamic objects and sun lamps in another layer, then combine both shadows by multiplying them and use the result with the diffuse shading from the sun calculated with nodes.

i will come back on the subject, but later in the year. See you