Friday, December 3, 2010

MachinimaMondays about LAG - 29 Nov. 2010, with Miro Collas



MachinimaMondays on November 29 (2010) - sim full, eye-opening meeting !!!


Recently I invited Miro Collas to share his knowledge about lag - and the myths and facts around it.


Rather then listen to a presentation or speech about something that affects our machinima's so profoundly, Miro and I had decided to do a Q and A for everybody present.

I cleaned up the chat a bit, to keep it read-able, and here it goes:

Miro Collas: There are 2 blogs about lag
Miro Collas: one in particular is VERY well written and is in fact cited by LL in their wiki.

http://analutetia.com/2009/06/22/anatomy-of-lag/

http://gwynethllewelyn.net/2008/02/16/lag-myths-dispelled/

This transcript is sent to MachinimaMondays group in Second Life too, if you want to attend our weekly meetings, join the group - or contact Toxic Menges, Phaylen Fairchild or Chantal Harvey inworld.

MachinimaMondays meeting, November 29, 2010:

Chantal Harvey: what is lag?
Miro Collas: ooohhh.... you start with a huge question.
Penumbra Carter: slows down and makes the camera jerk
Miro Collas: lag is not one thing, but 3 things, that are partly connected
first is client side, then network lag, and lastly, server lag.
Easiest to explain maybe is the second, network lag. That is essentially a measure of how good/bad your network connection is.
If you have a slow or poor network connection, you will lag.
Client-side lag involves ... well, things being drawn (rendered) on your computer screen.

Kit Guardian: can location have something to with that on any given day? Or hou much is being used around you?
Miro Collas: location matters yes. For client side, if there is a lot around you, then there is a lot to render, so more work for your computer to do
Kit Guardian: No I mean in RL
Miro Collas: Ah... it might, perhaps. Not so much distance as quality of connection, and speed of connection

Chantal Harvey: The distance to the Linden Lab servers, does that matter at all?
Miro Collas: there's a way to check your connection: visit http://speedtest.net/ and measure your bandwidth. Ideally, check it against Dallas
Georgianna Blackburn: why Dallas?
Miro Collas: Because a good part of LL's servers are now in Dallas
Georgianna Blackburn: ah, why?
Miro Collas: why there? That I don't know for sure, but it appears to be home to large datacenters
Dacob Paine: It's a co-location for redundancy and it is probably cheaper for their server farms.
Miro Collas: I'm afraid I don't have specifics on what is where, re: servers. But it is a good place to check against - better than a near-by city anyway
Chantal Harvey: Q even if u are in europe, as i am?
Miro Collas: yes. SL has no servers outside the US
Anyway, once you have checked your bandwidth, then you can determine an ideal bandwidth to set in your viewer
Chantal Harvey: ah i always wondered what my ideal bandwidht setting is

Inquisitive Loon: Dallas is not an option for the speed test?
Miro Collas: there is a star there for dallas, tho it is a tad hard to locate.
NicoleX Moonwall: i use a hughes net satlite so it floats
Miro Collas: Chantal: ideal is about 80% of the value that speedtest gives you
Miro Collas: 80%
Emmo Wei: Q is that 80% of the up or down?
Miro Collas: download
Miro Collas: upload is almost always far less
Dacob Paine: Q why is that?
Miro Collas: because generally, we download MUCH more than we upload, and 'net companies know this and allocate the bandwidth accordingly

Chantal Harvey: the burning question for machinima: what can we do to improve our framerate....?
Miro Collas: ok frame rate... that depends on many factors and so isn't easy to answer.
Most importantly, it depends on your hardware.
If you have a quad core PC with a high end vid card, you will get MUCH better frames rates than with say a dual core and a mid-range vid card.
(all else being equal of course) - a quad core will give better results than a dual core. And a faster processor better than a slow one
why is quad-core preferable?
Miro Collas: because then the work can be shared among the cores - which are essentially processors
If you enable it, it splits rendering off into another thread

Kit Guardian: Does our choice of software to film also effect the lag factor?
Miro Collas: it can yes. That's an external program which has to run at the same time as the viewer; it will use processor power.

is SL a multi-threaded app?
Miro Collas: multi-threading is enabled certianly in sl 1.23, snowglobe viewers; I cannot speak for Viewer 2
Miro Collas: or rather, *can* be enabled
Chantal Harvey: oh pls explain?

Apollo Manga: How many cores can SL multithreading use?
Penumbra Carter: Q what is multi threading :)
Miro Collas: multi-threading means that a single program can run several tasks at the same time (kinda); it boosts performance

Kit Guardian: which viewer is the best then?
Miro Collas: I have heard that Kirsten's is geared to machinima. Some I know use it for that specifically, and then revert to... whatever else for normal use.
Chantal Harvey: The LL 2.3 has a preset in graphics for 1920x1080, KirstenLee has shadows... each viewer has its own advantages and disadvantages.

Kayden Oconnell: -- Yes, would like a guideline for a new system, if we're looking to replace what we have -- not top of the line, but affordable?
Miro Collas: as for an ideal system: the more money you can throw at one, the better. It is that simple and brutal
Dacob Paine: lol so true
Chantal Harvey: think of it like this: a hollywood studio will cost a million, a perfect pc for machinima will cost 10,000 dollars
Miro Collas: it you want priorities for a system, then in order: CPU, video card, RAM, hard drive

Chantal Harvey: what will setting your bandwidth-slider too high do? does it influence?
Miro Collas: Chantal, yes it will - set it too low and you' you're throttling data
basicaly, slowing yourself down
Chantal Harvey: and setting it too high?
Kit Guardian: Crash perhaps
Miro Collas: that seems to also have negative effects, tho I confess to not fully understanding that part of it
Empirically, it has been worked out that 80% f your true bandwith is ideal for SL

Dacob Paine: can you give us an idea of the minimum computer someone needs for machinima?
Miro Collas: I lack the experience in that I'm afraid, it isn't something I have done. But let me give you an example....
I have a 3.2GHz quad core PC, 8GB RAM, and a GT240 vid card with 1GB RAM.
With that, I can have all my settings at ultra and a draw distance of 256m and not have issues
(well not usually)

Chantal Harvey: i have invited Ricky Grove to come and talk about computers, for machinima
Chantal Harvey: stay tuned... for that one, as he has agreed to do that for MachinimaMondays.


Apollo Manga: with a 64-bit system, is there a maximum RAM that can effectively be utilized? uhm... 32GB perhaps... not sure now.
Dacob Paine: That depends on the flavor of windows Apollo, it's up to 192 gigs at the most.
Dacob Paine: Some flavors are limited to 16 though
Miro Collas: btw, I'm on linux myself
Apollo Manga: Q but is there a limit on what can effectively be used? I'm building a 12gb system now but wondering whether to expand to 24gb
Miro Collas: that depends on the viewer you're using. All windows viewers (that I know of) are compiled in 32-bits
Note: go to: http://www.tomshardware.co.uk/ram-memory-upgrade,review-32053.html

Apollo Manga: Windows 7 Resource Monitor says I'm not using the 8gb I have now
Miro Collas: some of those include versions that can make use of extra RAM ... those are the LAA versions
Otherwise, a 32-bit app will use 2GB, no more
Apollo Manga: LAA?
Miro Collas: Large Address Aware

Chantal Harvey: i am on windows 7, 64 bits, do you know if sl will be compatible soon?
Miro Collas: Chantal: no clue on LL's plans for a 64-bit viewer

Kayden Oconnell: -- There seems to be disagreement about ARC -- Does that affect our computer? Or the sim where you're filming?
Miro Collas: Anyway, ARC... it stands for Avatar Rendering Cost. The "rendering" tells you it is about client-side effects, the number is a measure of hwo much work your computer has to do to draw an avatar
Miro Collas: ARC has NO effect on a region
Miro Collas: so.. if someone says, "you have high ARC and are lagging the SIM", they are misinformed
Chantal Harvey: wow listen to that, folks
Kayden Oconnell: Yep, the ARC police will tell you otherwise
Chantal Harvey: avatar rendering costs, are not causing lag
Graycon Sonata: omg
Miro Collas: similarly, if someone says that you're wearing too many prims and are lagging the sim, they are misinformed
Chantal Harvey: are u sure about that, Miro, and what arguments can we use
Miro Collas: I am quite sure
Miro Collas: however...
Miro Collas: if you are wearing too many scripts, then yes, you are lagging the sim
Miro Collas: people often wear a ton of scripts without realizing it - and those DO lag a region
Miles Eleventhauer: i've shot video moving next to a heavly scripted av and you can see the frame rate going down in the video
Kayden Oconnell: Q So, if you're at a region with terrible lag, and many avs -- the main lag is on YOUR computer? trying to rez everything?
Miro Collas: but here it is important to distinguish between client-side and server-side lag
Nave Fall: Q: How do we measure how many scripts we have on us?
Miro Collas: Kayden: it is both...
Ok, let me explain in brief what a SIM does... (and this will therefore be incomplete)...
Miro Collas: among other things, a SIM keeps track of where everyone is... as well as running scripts that are on the SIM, delivering textures to you, and so on.
These things are prioritized. Keeping track of avatars has highest priority
So when a SIM is full of people, the SIM is going to spend most if the time, tracking people
When it has done that, it will then deal with scripts and then it will deliver textures
Miro Collas: so... if you go to hair fair for example.... ;-) you'll be familiar with it being gray for a LONG time... because the SIM is too busy dealing with all the people
Chantal Harvey: Q is there a way to improve this.... at all
Miro Collas: but of course you can cut back some by removing as many worn scripts as possible before you go
If you are holding the event, then keep scripts to a minimum
Miro Collas: also, a neat trick: provide seating
Chantal Harvey: oh?
Miles Eleventhauer: people sitting relieves a laggy sim?
Kayden Oconnell: one script for all the seats?
Graycon Sonata: who knew
Miro Collas: backing up... if you're sitting, from the point of view of the server, you become linked to the object you're sitting on - therefore, the SIM no longer needs to track your movements
Kayden Oconnell: ohhh, ok
Miro Collas: you also become phantom.
Bryn Oh: thats interesting
Miro Collas: meaning you can go through walls
Miles Eleventhauer: do that would include dance pose balls at a club
Miro Collas: yes
Nave Fall sits right down.........

Chantal Harvey: how can you see these scripts?
Miro Collas: some viewers, like Phoenix, have a built-in way of counting scripts on avatars
Miro Collas: right-click your avatar, and select S.Count from the menu
Counting scripts. Please wait.
Counted scripts from 13 attachments on Chantal Harvey: 42
Miro Collas: that show how many scripts you're wearing - except for HUDs
Miro Collas: 42 is a very good script count - nice and low
Ideally, you want to keep your script count under 100

Kayden Oconnell: aos?
Miro Collas: Aos no.
Kayden Oconnell: thanks, Miro -- never had it explained like that before

Bryn Oh: so miro i have just begun to get jerky filming where i didnt before. If i wanted to get it smooth again for my spacenav what are some things to do... for example lowering screen resolution etc?
Miro Collas: let me address another myth.
Miro Collas: Bryn: first I'd shut down any other apps that you do not need, like browers, etc
Miro Collas: that way your computer has less to do
Chantal Harvey: yea i find skype and youtube lower my performance
Apollo Manga: Firefox with multple windows can really slow down performance too
Bryn Oh: ok
Bryn Oh: i get a spike every 5 seconds or so and not sure what it is
Miro Collas: then I think much will depend on where you are in SL. If a place is graphics-intense, your frame rate will be lower
Miro Collas: also, just the sky takes a lot of effort to be drawn
Bryn Oh: oh but i love the sky
Miro Collas: basically: adapt to the location and situation
Bryn Oh: sigh
Chantal Harvey: but switch off the clouds in (advanced) rendering helps
Bryn Oh: ok
Miro Collas: example: do you need water reflerctions? If not, turn them off
Bryn Oh: and minimal draw distance?

Kit Guardian: So sky boxes are not necessarily less laggy?
Miro Collas: No Kit not necessarily. Again, it depends on what you can see
Penumbra Carter: sky boxes, if open to the air will get sky flicker, I found
Miro Collas: the more you have on your screen, the more work yoru computer is doing... ergo, the more client lag
Miro Collas: and a specific case of course is particles
Penumbra Carter: especially if they are above 300 m
Miro Collas: particles are like ARC: they are totally client side, and do NOT lag a region

Chantal Harvey: what is post process quality, there is a slider for that?
Miro Collas: Chantal: I think that's "empty" - meaning there's a slider but no code behind it. ;-)

Miro Collas: what questions did I miss?
Kayden Oconnell: the lottery numbers for the next drawing?
Miro Collas: LOL!







Penumbra Carter: do you then lower your fraps to match the area?
Does changing the fraps to match the region help, sometimes it does, but then I was told not to match it to close to go up? does that make sense?
Miro Collas: you're presuming i know what frpas is. :-
Bryn Oh: how do you change fraps to do that pen?
Penumbra Carter: I change the fraps in my frap settings to match the fraps I see being shown on the sim Bryn let me tell you specifically, one sec
Bryn Oh: ok thanks.. i have not tried that
Chantal Harvey: yea bryn that is hugely important
Bryn Oh: oh good
Penumbra Carter: in the movie tab of fraps:)
Chantal Harvey: set it to reality (the actual framerate of your location), or fraps will double frames to match what you have told it to do...and thus create jerkly images.
If you set your fraps FPS at 30, while your actual framerate is only 15 when recording, makes fraps double all the images you shoot till it is 30fps….and that, is jerky film.
Penumbra Carter: but the sim can be jumpy, so do you go up from what you think is the highest fraps of the sim?
Chantal Harvey: I would suggest go as close as you can, and try to stay a bit under.

NicoleX Moonwall: how best to shoot in dark place with out a flash light?
Miro Collas: play with the sky settings to increase ambient light
Miro Collas: in there, go to Lighting and you'll see Ambient - you can raise the intensity to make the scene brighter
Miro Collas: assuming you're on a V1.x viewer, go to World -> Environment -> Sky settings.
Chantal Harvey: Q is there a setting that creates lag??? or less lag???
Miro Collas: you get a window where you can select preset skies
Chantal Harvey: are the presets less laggy?
Miro Collas: sky presets? not especially more or less... no. Ones with more clouds might be a tiny bit more laggy
Chantal Harvey: so resume... what is your ultimate tip to reduce lag....
Miro Collas: When it comes to lag, overall, it is important to understand the difference between the various forms. From there, you can understand how to deal with them.
Miro Collas: If you're at a public place, busy, then reduce draw distance, or de-render stuff and people. ;-)

NicoleX Moonwall: is it true the higher you go up the less lag?
Miro Collas: Nicole: not that I know of - except that there tends to be less stuff high up, so less to draw

Chantal Harvey: lots of movement will cause lag too? animations?
Miro Collas: scripts run on the server - which affects the entire region, regardless of height
Penumbra Carter: scripts = animation?
Miro Collas: movement will cause server lag *if* the avatars are not sitting
Miro Collas: animations, interesting, are played client side

Penumbra Carter: we will have alot of seated machinimas:)

Chantal Harvey: kk - so, scripts are the worst regarding lag monsters?
Miro Collas: naturally if you need movement then you must have it. You can try to compensate elsewhere, like by cutting back on scripts

Kit Guardian: Does it matter what the Machinima person is wearing? or just the actors?
Miro Collas: Kit: script-wise it matters yes
Kit Guardian: like shouldmwe not wear any AOS or Huds when filming?
Chantal Harvey: avatar rendering doesnt matter, but scripts running does, i think
Miro Collas: AOs are not so bad actually. The worst offenders are resize scripts in hair and Shoes
Penumbra Carter: scripts = animation?
Miro Collas: movement will cause server lag *if* the avatars are not sitting
Animations, interesting, are played client side

Kit Guardian: Does it matter what the Michinima person is wearing? or just the actors?
Miro Collas: Kit: script-wise it matters yes
Kit Guardian: like shouldmwe not wear any AOS or Huds when filming?
Chantal Harvey: avatar rendering doesnt matter, but scripts running does, i think
Miro Collas: AOs are not so bad actually. The worst offenders are resize scripts in hair and Shoes
Chantal Harvey: Miro, this is an eye opener, thank you very much.



Picture made by Kit Guardian

2 comments:

  1. Quite a good and clear synthesis.
    Thank you Chantal & MachinimaMondays for organizing and sharing ! :-)

    ReplyDelete
  2. too bad i missed this. thx for sharing !
    cisko

    ReplyDelete