Wednesday, August 21, 2013

Second Life performance and the state of Game Engines

Nalates recently published a post on the state of Game Engines and the performance of the Second Life platform in comparison. The article has also triggered an interesting discussion in the comments section.

Nalates thinks that the current batch of game engines in the gaming world exceed the capabilities of Second Life and she doubts that Second Life will ever catch up. Nalates shows a demo of the Unreal Engine 4 platform called "Infiltrator" and she comes to the conclusion that making something like Infiltrator in SL is currently not possible.

She says that in SL we have had the ability to use most of the tools professional game designers use; 3DS, Blender, Maya, and others for over a year. So, we could build pretty much everything one sees in games designed with the Unreal engine [...]. 
We can make the buildings, the characters… mostly, the clothes, and most of what you see in the demo video. We can even make most of the particle effects. What we can’t do is have the action displayed in the video; fast moving characters and massive explosions with shrapnel flying everywhere amid great balls of flame.

I would like to add that the main problem with the NPC characters is that we cannot animate and rig mesh in Second Life (unless creators use texture flipping - which is basically a hack. There is even a bug when this method is combined with Pathfinding).

Nalate thinks that the main reason why the Second Life platform has a worse performance is the lack of customisation: Games are optimized for performance at the price of reducing the freedom of what the player can do in the game world. Everything in the simulated world is optimized and designed with game play in mind. Also, everything in the game is designed to tease out the best performance from the hardware: the engine, textures, models… everything. All of that is optimized by professionals working to circumvent the limitations of the system.

Picture from NiranV Dean
This reminds me of a blog post by Niran V Dean when he explained why advanced lighting models work much better in most games: Most games seem to use a fixed high resolution shadow map. How can they manage to have such nice shadows without totally over-killing performance?

Second Life has no boundaries, our camera is free, the world is free. We can move and look wherever we want as close as we want. Games don't allow such a huge amount of freedom for a reason. What would happen if we were able to look very close at our shadows, at our textures, at everything? We would see all the tricks and hacks developers use to make our games look good without killing your performance. (Nalate calls this "the magic curtain".)

One of these tricks is the shadow map. Shadows can be a performance eater, especially if rendered in real-time like in SL. Games often use "baked" shadows or a low resolution shadow for let's say interior scenes, shadows from the sun are baked into the textures or map and never change or move or do anything at all, only "projected" lights from light sources use realtime calculation because it saves alot performance. Second Life does everything in realtime that other games do with pre-baked textures resulting in a huge performance drop. 

In SL shadow resolution is turned up to counter pixellation caused by a relatively high draw distances which is once more decreasing performance drastically. Basically the coders of the viewer need to double the resolution of our shadows for each time that the draw distance is doubled, that means 64m = 1.0x , 128m = 2.0x , 256m = 4.0x , where 2 times is often already the moment at which most GPU's will bail out and produce low framerates.

That's why I think that it is so important to keep the draw distance as low as possible when turning on advanced lighting in Second Life. You should keep it between 96 and 128 meters.

Another difference between modern Game Engines and Second Life is that the first are based on DirextX while the latter are based on OpenGL. OpenGL is still behind DirectX and not as stable since it’s still ongoing development. This might hinder progress.

Picture of a Second Life landscape from nicotime
So, from a technical side it's probably safe to say that the Second Life platform won't be able to compete with Game Engines any time soon. But what could be a future performance that makes us happy? Nalate reminds us that SL tech is improving. The visual quality took several steps forward with the release of the Materials System. Performance is improving with the advancements Monty Linden is adding to the HTTP communication channels. Rez times are dropping as Andrew Linden changes the Interest List. Game controls are changing, which we will see when the Advanced Experience Tools get released.

But how good could the Second Life platform get? Nalate thinks that one other problem holding Second Life back is that content creators in Second Life are not professional game designers. They like to design stuff and game play is secondary. For those using the Unreal engine, game play is primary. The different philosophies and criteria lead to different end results. If people optimized content more, SL would perform way better too. Nalates thinks that at this point the designers are the ones that can advance the appearance and performance of Second Life the most. As their skills grow they can learn to remove unnecessary load from the servers and viewers.

Speaking of professionalism: the new game from Mapea Unia seem to push the boundaries of what people think is possible with the SL platform. There is a new post on the Madpea blog saying the game "will be something so amazing and mind blowing, that Second Life will never be looked at the same way again". The MadPea crew aims "to bring truly an experience like none other". Madpea has been teaming up with some of the best content creators in their field to secure the best possible outcome. But if we look once more at the preview scenes that Draxtor presented us and compare them with the Unreal Engine demo, then the performance gap between the two demos seems to stay incredible huge. 

So is it fair to say that the difference between the two derives from the level of professionalism? I don't think so - the two examples rather show the upper limit of what people are able to do with both platforms and it is not possible to fairly compare the creations between platforms with each other because of the technical limitations stated at the beginning of this post. I am totally looking forward to see how Madpea will be pushing the limits of Second Life as a game engine.

1 comment: