Midian City
FAQ FAQ Search Search Memberlist Memberlist Usergroups Usergroups
Register:: Log in Log in to check your private messages


Post new topicReply to topic
Reduce lag. :D View previous topic :: View next topic
Author Message
Soap Clawtooth
PostPosted: Wed Aug 06, 2008 3:58 am Post subject: Reduce lag. :D Reply with quote



Joined: 27 Jun 2008
Posts: 130

One of the biggest causes of lag, after being around enough to figure it out, i find is textures! Rather than the prims.

Why textures? Because many people don't optimise their textures!

I'm mostly talking about the stuff on posters, etc etc. Now we ALL want everything to look the best it can, but texturing in Second Life is no different from building a webpage when it comes to the images.

As a web designer and graphic designer I am forced every day to make diplomatic decisions on the quality of my work against the speed that the website should download at.
When I make the images I have to give them the best quality with the smallest file size possible. Second Life works in exactly the same way as a website in this regard. The textures/images are stored on the server and your client has to download that image in exactly the same way that your web browser has to download images from a web server.
Now usually the best way to do this is with a .gif image, so start using those. But if you want to use a .jpg image then for god sake OPTIMIZE IT!
That's right!
Now, firstly when you go to save your GIF image from photoshop always follow these principles.
Flatten all your layers to one layer. The more layers you have in the .psd when you save it to .gif, the larger the file size will be.
Always use 'save to web & devices' This causes photoshop to automatically calculate how it should save the overall image for the smallest filesize possible and will tell you the current filesize in the preview window and also roughly how long it will take for your browser to download it at its current file size - so for example the header for this forum is currently set to 2.679K, which would take about 2 seconds to download on 4mb connection. (I have 20).

Now not ALL of your images are going to be gif, some will be jpg and some will be a lot larger than that image up there. So, to reduce lag, remember these things always.

1) Resize everything you do to 512X512 before you upload it. Second Life automatically resizes everything to that anyway so making it larger only causes you to have a huge file with less quality than if you'd taken the time to press CTRL + ALT + I in PS and resize it.
Your image may not be square in nature - so make sure that it is the LENGTH that you convert to 512, photoshop will resize the height for you automatically. Or if its not square and you want it to be - uncheck the 'constrain proportions' box in the resize image dialogue.

2) When you save in jpg format NEVER bump up the slider to 12, there's no point. Ideally you want a 512X512 jpg to be 49.6K or lower, (depending on the original filesize, I used an image that was originally 310K at Best quality to generate these figures, even at below half quality there was no noticeable degradation to the image.).
The 'magic number' of filesizes is 30K for jpg's and lower. Oviously if you're using an image smaller than 512 square you should still try to decrease your filesize as much as possible, like with the forum header.

It is a basic rule of web design and should be no different if you're texuring and uploading posters to SL because the client calls the images in the same way. So, the larger the file size, the longer it takes to download, the more space it uses in your cache, the longer it takes to rez, the more your viewer has to do to reposition it in relation to your avatar when you move and this will equate to LAG! >Sad

I hope this helps some people out.
_________________
Back to top
View user's profile Send private message
Stephan Nephilim
PostPosted: Wed Aug 06, 2008 4:48 am Post subject: Reply with quote



Joined: 05 Jul 2008
Posts: 42

Thanks, I know I'm always hesitant to cut down the detail level on my 512x512 textures because of competition, but I figure for Midian at least I should be optimising as much as possible. I'll be seeing about optimising all the textures I use in Midian in the coming week.

I could use some advice on optimisation though. I used the jpg slider for optimising, put it down to 3 with visible degradation and the 512x512 image is still 79k. Any other tricks might help optimise a jpg further?
Back to top
View user's profile Send private message
Soap Clawtooth
PostPosted: Wed Aug 06, 2008 5:31 am Post subject: Reply with quote



Joined: 27 Jun 2008
Posts: 130

Sometimes I save it and save it again. Double Optimization, but the quality is generally low....

Using more basic colors helps. Flat colors require lower filesizes as an an oppose to things with gradients, etc. Only putting in the effects you need, rather than the effects you want and not using too many filters.
_________________
Back to top
View user's profile Send private message
Ayami Imako
PostPosted: Wed Aug 06, 2008 7:02 am Post subject: Reply with quote



Joined: 12 Mar 2008
Posts: 29

Just to chime in ... and I agree with everything said for the record so this is an addendum ... two of the largest culprits texture wise are animated and alpha textures. Granted they can both be used to great effect but decide if you really need the buttons on your shirt or your eyes to swirl between 7 shades of light red so much.

Another major cause of lag in Midian .. and I add is against Midian's rules but people love to do it anyways is the use of active 'pingers' such as radars and targeting huds. These don't just cause you lag but every one around you. And when you have ten people in a scene and five of em are using em it can turn things to mud real fast like.
_________________
~Aya~

Characters:
Ayami Imako - Catwalker Prowler/Lead Trainer
Danica Forster - MPD Officer

Pics:
http://www.flickr.com/photos/aimako/
Back to top
View user's profile Send private message
Soap Clawtooth
PostPosted: Wed Aug 06, 2008 10:04 am Post subject: Reply with quote



Joined: 27 Jun 2008
Posts: 130

Also. WEAPONS! If you have to holstered, you might do well to detach the invisible gun from your hand until you know you're going to need it, the holstered version of your gun has way way less scripts than the unholstered.
_________________
Back to top
View user's profile Send private message
Mordag McCallen
PostPosted: Wed Aug 06, 2008 1:25 pm Post subject: Reply with quote



Joined: 15 Jan 2008
Posts: 399
Location: Bunker

Soap Clawtooth wrote:
Also. WEAPONS! If you have to holstered, you might do well to detach the invisible gun from your hand until you know you're going to need it, the holstered version of your gun has way way less scripts than the unholstered.


This is actualy interesting circle... since when having my invisible weapon detached, I risk that it wont atach at all when I need it (I suppose we all know this issue when SL wont let you atach things, quite likely due to lag). On the other hand if everyone had network friendly textures and detached invisible weapon, it would of course work good, but we know that wont happen anytime soon, so the lag stays high and so people are reluctant to detach invisible weapons since they wont be able to atach them in need and increase lag.

I have myself gutted all the hand held weapons I could to have version with no scripts at all as lag-friendly solution. I do mostly emote combat anyway.
_________________
Cpt. Mordag McCallen, BEng(1), SrTech 1st class
Back to top
View user's profile Send private message
Display posts from previous:
Post new topicReply to topic Page 1 of 1

Jump to:



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


DAJ Glass (1.0.8) template by Dustin Baccetti
EQ graphic based off of a design from www.freeclipart.nu
© 2007-2008 Informe.com. Get Free Forum Hosting
Powered by phpBB 2001, 2005 phpBB Group ::