Thursday, 21 February 2019

Immersion

Immersion

(How we perceive the world)

Originally posted in a discussion at the Second Life forums.

When we create something for a virtual world, we want the viewers to loose themselves in it, don't we? We want immersion, we want people to believe this is real! But a virtual reality is not and will never be a detailed copy of Real Life. Nor should it be. In that sense it will never be real and that means people will need to "suspend their disbelief", that is accept that a couple of core factors are different from how they usually are.

There are several well known and proven techniques artists of all kinds use to facilitate suspension of disbelief and immersion. You can play around with timing and with deliberate use of distractions, you can prepare and build anticipation, etc., etc.

To make the most out of these techniques, we need to understand a little bit about how our brains work and how we perceive things. Here are a few factors to consider:

1. We don't think what we think we think

There's so much going on in our brains that we are not consciously aware of. Much of it is never recorded in our memory so it's gone forever in the blink of an eye.


2. We don't see what we think we see

I'm sure we've all been told that what we see is only ten percent what our eyes actually register, the rest is how the brain interprets the data. (Imagine a large list of optical illusion examples here.)


3. Our senses interact

(I could have added long explanation with lots of examples here but I think most people can come up with that themselves.)


4. There are limits to how much we notice

Most of what goes on around us is unnoticed. The brain simply doesn't have the capacity to handle it all so it focuses on what seems important at the moment and ignores the rest.


5. Memory works by association.

New memories are never stored independently, they are "hooked onto" exisitng memories. The more such "hooks" the brain can find for the new data, the easier it is to remember. This is very different from computer memory where every piece of information is stored separately in an orderly fashion. Two of the many consequences are:
  • 5b Almost everything we remember is wrong When an old memory is used as a "hook" for a new one, it is inevitably altered a little bit.
  • 5c First impressions are important Because that will always be one of the strongest "hooks" for subsequent related experiences.


6. Perception is holistic

It's far more about the whole picture than individual details.


7. Our brain is always looking for patterns

If there are no patterns, it makes some up.


8. Things that seem out of place will always draw a lot of attention

I suppose that's just another way to put the previous two points but it's important when we're talking about immersion factors. Put an organutan in a Borneo jungle scene an he fits perfectly in. Seat him in the parliament and he stands out like the proverbial sore thumb (or maybe not but you get the point). My definition of an eyesore, a common SL immersion breaker, is not something that is ugly - an eyesore the way I see it can be really beautiful and amazing. But it breaks the continuity of the scene and draws attention away from what is more important to the whole.


9. The brain is not alone

It's our cpu, yes, but it doesn't do all the work, it is thoroughly integrated with our entire nervous system and even our entire body.


10. Vertical is more noticeable than horizontal

Imagine you are hiding behind a rock and want to take a peek to see what's going on. Stick you head up above the rock and everybody will notice you, sneak a look around the edge of it, and you'll probably get away with it.

I'm not sure if this has anything to do with how our brain works or if it's simply that higher objects tend to stand lut against the background of the sky but it's certainly real and it's something well worth keeping in mind when you want to direct your audience's attention. Point upwards if you want to draw attention to something, sideways if you want to tone it down a bit.


And finally, Chin Rey's addendum to an old publishers' slogan: 

11. Content may be King but without Queen Context, he is nothing at all.



I don't know how Linden Realms are these days since I haven't tried it after they changed it. But it used to be one of the most immersive parts of SL and it's a good example how immersion factors can be applied here.
One thing that is obvious there, is that it's not about highly detailed graphics. The LL scene is about as low poly and "crude" as it gets in SL. But everything had a conistent style, there was nothng there that stood out and stole your attention. Except the crystals of course but those were the items you wanted to draw attention to. The low resolution simplified graphics actually helped a lot there because it made it easier to integrate whatever wacky avatars players and sabouteurs showed up with.
The Linden Realms music stream helps a lot too. It's actually brilliant, carefully designed to set a mood and emphasize rather than draw attention away from the visual scene and the action.
Of course, it also has something as rare in SL as speed. That always makes immersion so much easier, there's no time for your mind to wander.

Basic principles for good content creation

Basic principles for good content creation


Some (well, only one for now) more "philosophical" articles about the general principles for good content.

Index

Index

What's in this blog (so far):

Thursday, 14 February 2019

Texture scaling

Texture scaling


Inspired by a post at Beq Janus' blog.

Second Life and the Hypergrid only support a few texture sizes and if you want good performance, you want to keep them as small as possible. That means they usually have to be resized to work and the rule is:
Scale your textures before you upload them!!!
Why?

Because there are different ways to scale an image and which is the best depends on a lot of factors. Often when people complain about poor resolution it's actually the scaling algorithm, not the pixel count that is the problem.

The texture uploader uses bilinear scaling. That is actually a good choice when you don't have a choice. But if you let your image editor do the job, you do have a choice and that is always better. It also means you get to see the result before you upload so you don't get nasty surprises afterwards.

The alogrithm I've found to be the best most of the time is neither bicubic or straight bilinear but Fant - a variant of bilinear you won't get from the uploader but as I said, there are exceptions.

For all the nerdy under-the-hood details, check out the wikipedia article about image scaling.

A special tip:
Sometimes a little bit of blurring (usually before scaling) can actually improve the perceived resolution. You can do this with Gaussian blur or by saving the image in the lossy jpeg format. Yes, I know this seems counter-intuitive but it does make sense. Quite often it's the graininess caused by high contrast neighbour pictures that is the problem, not the resolution. Blurring smooths out the texture and that can often help. Not always, but it's worth trying.

Textures

Textures

Tuesday, 12 February 2019

Bigger prims

Bigger prims

Here are some cool and useful Prim builder tricks.

Officially the maximum size for any object in Second Life is 64x64x64 m. On the Hypergrid and other opensim based grids, the limit is 256x256x256m.

There are "megaprims" in Second Life. These are old prims some content creators were able t create due to two old (and quickly fixed) bugs. The biggest of them is a whopping 65,536x65,536 m, big enough to cover 65,536 whole sims (In theory at least - they won't actually have any effect that far away from their root location).

But even without mega prims, there are ways to extend them beyond the official size. And in Second Life we also have the option to link two prims, force them over to the modern LI calculation and have them count as a single land impact combined.

I once posted a challenge in the Builders Brewery and later I reposted it on the official Second Life forum: How much land impact does it take to cover a whole sim completely with prims without using megaprims?

The obvious answer is 16 64x64 m prims but there are several ways to reduce it. I had four (or rather three-and-a-half) ways in my mind when I posted the challenge and two replies in the forum discussion came up with other solutions using scripts and - one of them - temporary objects.

I'll ignore the two scripted alternatives here since they're not really about prim handling (and also are quite heavy on the poor server). But my three-and-a-half answers are:


Solution 1: Slightly smaller linked prims (11 LI)

As I said, you can use modern LI calculation to make two linekd prims coutn as only 1 LI combined. Unfortunately you can't do that with side-by-side 64x64 m prims because of the 54 m limit to the distance between linekd objects.

But you can link them if you reduce their size along one axis a little bit. 54x64 m is enough althoguh I usually prefer slightly less (50x64 m). Ten such pairs plus a sngle prim is enough to cover an entire sim, bringing the land impact down to 11.


Solution 2: Top shear (8 LI)

Top shear is one of the prim twisting parameters and what it does is shift the top of the prims to one side, extending it up to 50% outside its nominal size.
Here are two such prims (colour coded for clarification), side by side and linked:

Between them these two prims cover as much ground as three unmodified prims and combined with Solution 1, they are still only 1 LI.

This way it is possible to reduce the total land impact for a full sim coverage to 8.


Solution 2 1/2: Double top shear (? LI)

You can top shear along both the x and y axis to cover even more ground with a single prim. The problem is that you end up with rather irregular shapes and will have to overlap and/or add smaller filler for a complete coverage. Don't ask me how low you can get the LI this way. Thinking about it makes my head spin.



Solution 3: Reverse taper (4 LI)

This is a bit special and needs a long explanation.

 Prims are "procedural" (aka "algorithmic") objects, that is the viewer is fed some basic parameters and generates the right shape according to those. As far as I can figure out, there are 14 bytes of parameters - give or take one or two, depending on exactly how the LL programmers thought at that time. That means there are 5,192,296,858,534,830,000,000,000,000,000,000 possible prim shapes. The software converting the prims to viewable mesh can generate all those shapes with no problems and none of them are harder or easier for it to handle than the others.

Most of those shapes are not available through the regular builder pallette or lsl though. They have been left out, some for obviously good reasons, others for more questionable ones. But after the viewer code was released as open source, somebody decided to take a closer look at this and added some extra functions to the builder palette giving us access to a few (but not nearly all) of those "secret"  prim shapes. These functions are still included in many third party viewers.

The parameter we want to look at in this particular case, is taper. Of course, tapering a prim normally means less surface area at one end of the path, not more. But it is actually possible to "reverse taper" it like this:


This prim is nominally 0.5x0.5x0.5 m but with "reverse tapering" the top surface is 1x1 m. Scale it up to max size and we get 128x128 m on the top, enough to cover a quarter of a sim. This is a legacy prim so the nominal land impact is 1. The actual LI can be a bit higher because of the physics weight but that's easily corrected by setting it to convex hull.

Prims (Primitives)

Index: Assets: Prims (Primitives)

Prims (Primitives)

Related articles:

Prims - or primitives as their full name is - are the original builders' materials of Second Life. Prims are "procedural objects", that is, they are generated by the viewer according to a fairly small set of parameters. You can think of prims as Minecraft on steroids or a simple version ao Archimatix if you like.

The advantage of prims over mesh is that they require far less data than mesh. This is essential for streamed virtual realities where bandwidth always is a major limiting factor and I think we ought to use them as much as possible and far more than what is common today.

Another big advantage prims have, is that you can create them and build with them in-world. Not only is that more fun (at least I think so) it also means it's easier to adapt your build to the surroundings and make adjustments later.

The prim system was developed by Avi Bar-Zeev 2002-2003. A few years later Bar-Zeev tried to write an article explaining how it all works but he seems to have given up because there har been so many changes to it after he left Linden Lab. Even so, the first version of his article is still well worth reading for those who want to understand that goes on under the hood in Second Life and on the Hypergrid. I have some plans to pick up where Bar-Zeev left and expand on his explanation. I'm not sure if I'll ever manage to find the time but stay tuned!