Saturday, March 28, 2009

They're called "Shaders"

Everyone is swooning over the darling of virtual environment engines, Crytek. Used for such things as Farcry, Farcry 2, and the infamous Crysis. The Crytek engine (now in Crytek 2 and recently announced Crytek 3) sports very impressive graphics for a game engine, and in many cases reaches into the realm of near photorealistic.





While the Crytek engine series is very impressive, there is a very simple explaination for why this engine is so graphically amazing. The secret is Shaders. HDR Shader, Bloom Shader, Depth of Field Shader, Motion Blur Shader, Atmospheric Scattering Shader and others all working in concert.

Add to that some lighting shaders and soft shadow shaders for Shader Model 3, and you begin to understand just what the Crytek engine series is all about. This isn't to say that the Crytek series is not impressive, because it really is. But running that many shaders simultaneously is obviously going to require serious hardware (as if you didn't know this already).

If ever you doubt this, simply turn on the shaders for SecondLife and you will see that it does have a negative impact for less than stellar hardware.

Breaking down the Crytek engine series a little further, let's look at the ocean system. Ocean surf, 3D water, refraction and reflection... Ocean Surf is a Shader. 3D water is easily taken care of by Projected Grid techniques, refraction and reflection are also shaders applied to the surface and under surface.

Add to that 11x Antialiasing on the hardware, and the environment looks fantastic, although you must admit that a majority of the greatness for Crytek happens to lay in shaders. Tesselation routines can take care of the terrain, and as for the trees and vegetation, start with high end tree models (we suggest from XFrog.com), and add PhysX or Havok Soft Body Physics to them. Now you suddenly have gorgeous looking trees with destructibility and reactive behavior to the wind.

Throw in Parallax Extrusion for textures, and now you have simple and more realistic 3D surfaces without building geometry to handle it. This would be the solution for things like the sand on the beaches or brick walkways.

Combine soft shadows on the GPU with Per Pixel Lighting, as well as a handful of other shaders (like Volumetric lighting) and suddenly everything looks photorealistic. But the real question is - if all of these "innovations" are just shaders, is access to the Crytek series of engines really worth $750,000 and higher? How about the ridiculous requirements just to qualify for using these engines?

Crytek has a commodity and has made a name for themselves in the industry as the company which brings you amazing landscapes and photorealistic environments. By doing this, there is enough hype around them to warrant the lunacy of being the "it" engine to use for a gaming or virtual world project.

Problem is, a majority of Crytek is simply using Shaders to achieve the photo realism. Shaders which just about any 3D Engine on Earth can easily use right now.

So the reality of Crytek is that it's an impressive engine, yet it's not special in any way other than the fact that most game development houses are currently too lazy to develop engines themselves or work on the shaders to use for their current engines. Crytek happens to be the lazy man's way out when developing, and is the quick and dirty way to jack up the hype around their project (by being specially selected to use the Crytek technology) as well as look visually stunning with little to no hard work.

Any hobbiest programmer can match the Crytek engine using something like OGRE3D. Just include all of the required shaders, define high definition content, and use high definition textures. The only real difference is that Crytek was the first group to go ahead and put it all together professionally.

In the end, $750,000 + just to license an engine which is essentially a bunch of shaders seems a bit overboard. But weirder things have happened in the game development world.


Monday, March 23, 2009

From The Front Lines

Some news to report from the front lines:

Adaptive Mesh Prototype

Essentially it's a tessellation routine for our planet system which reduces the mesh complexity based on distance. When the viewer gets within a certain distance of the planet, the system begins to resolve the landscape itself including mountains and terrain.

This is good for such things as a seamless transition from planet surface to space and back, aka: Google Earth style. Except that we plan on having multiple planets in the virtual solar system, as well as eventually many solar systems in a galaxy (continue scaling up to get the big picture).

Adding to this is the combination of Mesh Reduction LOD in order to handle the objects on these planets as you get within view to begin loading them. As a result, the mesh reduction LOD system should allow for a visibility range to the horizon without adverse effects on the rendering engine.

If you are an Active Worlds user, then this means the visibility menu is obsolete.

The next step is to figure out a dynamic tessellation routine.

Some Musings

After looking over the tessellation routine in action with a virtual planet the size of Earth, something has dawned on us that we didn't previously realize. An entire planet in A3D may be overkill for the standard needs of the average client/user.

If the largest "world" that ActiveWorlds has in their "universe" is the size of California, and they have yet to completely fill it ten years later, then the main planet of Andromeda3D may never be filled at all.

Which begs the question... is A3D simply too powerful? At the moment we're not going to question the power of the system, but we may have to offer planets that are orders of magnitude smaller than Earth to our customers.

Saturday, March 21, 2009

"Let Love Be Your Energy"

I've been in quite a chipper mood recetly (Hi K x), so I thought I'd share the mood by digging out another music video that makes me happy.

Robbie Williams' "Let Love Be Your Energy" is quite an upbeat song, with a nice dip just before the end, followed by a triumphant key change with fanfare at the end. The video, mainly an animated Robbie running, is also quite amusing as he dallies with a number ladies before finding the right one for him.

And those of you in the UK and USA that have seen the video probably chuckled at the very twee ending that is subverted in the last few seconds by an eagle.

If you haven't, you can watch it here. Go watch it before you carry on reading. I'll be right here ;)



Back again? Good wasn't it?

Now imagine my surprise when I found a version labelled "uncensored plus out-takes".

The ending is completely different! Instead of running up the mountain, embracing, and plummeting to a heart shaped spalt, Robbie and his dream girl strip off, and embrace naked to a background of erupting volcanoes (very subtle lads!).

And the out-takes at the end are very funny (and quite painful!) Take a look:

CAUTION! Contains animated dangly bits, and a few rude words!

Wednesday, March 18, 2009

Prayer Points - March 2009

This recently went out on our prayer points mailing list:

Dear Supporters,

Thankyou for continuing to pray for the Connections Church project in Somerset. Thankyou in particular for those who have prayed for us over the summer while we have been meeting in the local park. We have recently moved our Sunday gatherings to a local primary school. If you would like to see photos you can click here: http://will-briggs.blogspot.com/2009/03/big-blue-gym.html.

Some prayer points for this month:

1) Please pray for our transition into the school hall. Particularly pray for us with the ongoing contact this is producing with many in the community.

2) Please continue praying for the number of couples amongst us who have recently been married or who are getting married shortly. Pray for good beginnings, good foundations, and a firm awareness of God's grace.

3) Our "Search for Life" lifekeys program has recently started. Please pray for those who are participating, for insight, courage, humility as they encounter the opportunity to grow in God.

4) Continue to pray for those who have leadership roles within our congregation.

5) Please continue to pray for the newcomers in our midst, for a sense of belonging and believing together.

6) Our KLT (Kids Learning Time) ministry on Sundays needs more (childsafe-endorsed) leaders. Please pray for new helpers and leaders and the necessary processes to get them on board.

God bless,

Will.

Sunday, March 15, 2009

What's Our Culture?

Following a train of thought they began with my recently reading a book is this quote from the Lausanne Movement's Willowbank Report which makes an attempt to define what culture is. I'll quote their definition with a re-arranged layout:
Culture is an integrated system:
  • of beliefs (about God or reality or ultimate meaning),
  • of values (about what is true, good, beautiful and normative),
  • of customs (how to behave, relate to others, talk, pray, dress, work, play, trade, farm, eat, etc.),
  • and of institutions which express these beliefs, values and customs (government, law courts, temples or churches, family, schools, hospitals, factories, shops, unions, clubs, etc.),
which binds a society together and gives it a sense of identity, dignity, security, and continuity.
So here's a question for you, if you are reading this and you live in (or know) the North West of Tasmania. What is our culture?

Placing yourself as an ordinary/average member of the North West community - what are your beliefs, values, customs, and valuable institutions?

Leave an answer in the comments or email me.

Big Blue Gym

As promised, here are some photos from our move to the "Big Blue Gym" at West Somerset Primary School.

We have now been meeting at the gym for two weeks. We have access to the gymnasium pictured and also to a nearby multi-purpose room for our KLT (Kids Learning Time) ministry during our gatherings.

Our first week in the gym.
Note the tent from the park as a way of marking the transition!
Photo courtesy Jonathan Adamczewski


For a large hall the atmosphere is great. It's comfortable, open, airy, accessible.

It's very much "in the marketplace" with contacts being made simply by being there. God is good.

Bible time during our second week at the gym.
Photo courtesy Jonathan Adamczewski

Thursday, March 12, 2009

A Heart-felt Conundrum

We have recently moved in to our new venue at a local primary school. (I'll blog about that later, hopefully with photos).

This is a great thing. It places us as a gathered community in a physical place that is acceptable and accessible by churching and non-churching alike. It is bearing fruit - already, on our first Sunday - we had neighbourhood kids asking what we were doing. This is a good grounding for good missional stuff.

But then comes the conundrum. These kids also asked (or looked like they wanted to ask) "Can we join in?"

Can they?

The evangelist and mission-heart in me says "Yes! Come on in! Hear about Jesus. Hang with your friends (they go to the same school as some of our church children). Be blessed!" Find a loving community, a place of peace, a safety, a source of life!

But the administrator and overseer in me knows that I can't. Who would have duty of care for these children? We could set up systems of permission slips and other things - but how can I tax our overly-taxed kids ministry volunteers even further by putting further responsibility on them? Do we want church to become a pseudo-babysitter? What about our philosophy of having a multi-generational gathering with Kids Learning Time (KLT) happening during the "teaching/sermon" part of the meeting? Who would be in charge of these children when we are gathered as a whole - or should we only invite them to the KLT bit?

At the moment our line is "Yes, we'd love to have you join in, go and get your parents or someone to look after you."

But that means we turn them away. And we'll become known as the ivory tower church that's available for the families-who-have-got-it-together. We'll be teaching them "Jesus is for those "other people" and not for me."

And that breaks my heart. What to do?

Sunday, March 1, 2009

A Recipe For Awesome...

One of the recent endeavors that we have been on here at Andromeda3D is to figure out a solution for one of the oldest problems in virtual worlds. That is, how to easily allow the user to make their avatar look like themselves should they choose to. One popular approach is to simply take two photos of the subject, one from the front and another from the side, and wrap a face map to a generic model of a head. While this is fairly quick, the results aren't so good in the end as the face map tends to warp and stretch to the incorrect mesh.

The obvious solution would be to have an algorithm analyze the
photo and then mold the facial features of the mesh to fit the photo. As you can imagine this is no simple task, but with a bit of research it was discovered that there are definitely ways to accomplish this.

So we find a photo of an individual with which we would like to import into the system as a 3D representation of the face on an avatar, and we allow the algorithm to analyze the photo while actively morphing the model to match the features.


In our test, we chose a familiar face to work with -

If we take into account that this was the photograph imported into the system, obviously not an ideal front shot for 3D modeling, we can see that the result of the algorithm and mesh matching are indeed impressive, as shown below:



But this is not the end of the brainstorming and technology think tank session, by no means. The facial generation system also rigs the animation points on the model so that phonemes are also incorporated. The first thing this brought to mind was allowing the mouth to move realistically when speaking, but not on a post process sort of manner.

What if we marry this technology together with the VoIP system, then marry those two together with a Real Time LipSync system so that not only would the user have the ability to look like themselves in the virtual world by importing a single photo, but also have their virtual lips sync to their VoIP conversation as well in real time?

Now we're getting someplace. After a bit more research into this idea, we came across an SDK which allows just that - real time syncing of streaming audio to mouth animations based on phonemes. Not only can the avatar look photo realistic, but it can actually move its mouth properly when you speak. The downside so far is that the delay in audio processing is about 10ms, which in the grand scheme of things isn't actually that bad.

As for the face generation algorithm, on a decent computer with a good graphics card the process should take roughly 2 - 5 minutes to create the custom face and head. On slower computers (or computers with bad OpenGL Drivers) this process can take an extended amount of time into the 10 - 20 minute range for completion.

While the generation process may be slower on outdated computers, it still works the same way with the same results. So it's a matter of whether the user wishes to wait for the customization process to finalize or not. There is a definite up side to all of this in that once the face is customized to the photo, the file generated to recall the data is around 40 - 50kb in size and the calculations for mesh morphing are not required again (unless the user imports a new photo).

Then we add to this chain, yet another feature we've been working on. The Shader Skin process by which a procedurally generated skin texture is applied to the mesh as a first layer, then the face map is applied as the top layer, adjusting the opacity and color to come to a close approximation and create a seamless transition.

As for hair, again we're looking at Shaders for high end computers or premodeled hair geometry for slower systems. nVidia has been doing some interesting research concerning realistic and physX enabled hair in real time, so we'll be definitely keeping an eye on that.

Let's take a moment to recount our recipe for awesome -

1. Import photo which then automatically is analyzed to create a matching 3D Mesh for avatars
2. Apply real time LipSync technology to a VoIP stream
3. The facial animations of the model are already rigged and ready for use in the LipSync scenario
4. Real Time Shader Hair with PhysX
5. Procedural Skin generation to blend seamless between face and rest of body

Since the Digital DNA profiles of people are very small files, comparing a generated file to one on file already (such as Robert Downey Jr.) would be fairly easy. This would enable us to make sure people who are importing a photo aren't importing a known celebrity in the database who has requested IP Protection from Andromeda (Part of the VIP Program).

For the time being, this is definitely an avenue of research which we wish to continue as we put this virtual universe together.

- The Management