media file sizes
Moderator: Forum Moderators
Forum rules
Before posting a new idea, you must read the following:
Before posting a new idea, you must read the following:
-
- Posts: 5
- Joined: April 24th, 2006, 12:37 am
- Location: Florida, USA
- Contact:
media file sizes
i love battle of wesnoth. and i think the media is incredible, but i've noticed that the game images and sound take up almost 50% of the entire size of all game data. if the image files were converted to a lower bit at final run or even *.gif, couldn't that potentially save some space? i dont know if there is anything much that could be done with the media files, since it seems that *.ogg is the standard in open source audio, perhaps some form of compression?
The files are already compressed as much as they can be in the .png format. We don't use .gif, IIRC, because it isn't Free, so there are no Free graphics libraries that can display .gifs.
For I am Turin Turambar - Master of Doom, by doom mastered. On permanent Wesbreak. Will not respond to private messages. Sorry!
And I hate stupid people.
The World of Orbivm
And I hate stupid people.
The World of Orbivm
The UNISYS patent on LZW-78 (which is what *.GIF trips on) has mostly expired, although the date varies by country. The patent expired on June 28, 2003 in the U.S. EU, Canada, and Japan all saw the patent expire somewhen in June 2004, assuming no last-minute renewals and that the EU really can be treated uniformly. Cf. http://news.bbc.co.uk/2/hi/technology/3007862.stm.
More critically, *.GIF is limited to 255 colors for images with index transparency. *.PNG supports truecolor images and alpha transparency, and is simply a superior format for Wesnoth. Filesize problems aren't an issue after running pngcrush with the --brute option.
As such, there's no need to use a nonstandard libjpeg-6b, with *.GIF support imported from from libjpeg-6a, in building libpng.
More critically, *.GIF is limited to 255 colors for images with index transparency. *.PNG supports truecolor images and alpha transparency, and is simply a superior format for Wesnoth. Filesize problems aren't an issue after running pngcrush with the --brute option.
As such, there's no need to use a nonstandard libjpeg-6b, with *.GIF support imported from from libjpeg-6a, in building libpng.
Indeed. We need proper transparency, .gif doesn't have that.zaimoni wrote:More critically, *.GIF is limited to 255 colors for images with index transparency. *.PNG supports truecolor images and alpha transparency, and is simply a superior format for Wesnoth. Filesize problems aren't an issue after running pngcrush with the --brute option.
- irrevenant
- Moderator Emeritus
- Posts: 3692
- Joined: August 15th, 2005, 7:57 am
- Location: I'm all around you.
Re: media file sizes
I think this is essentially a truism. Images and sound are, by their nature, big files - even when compressed (which they already are in Wesnoth), and you'll find that in almost all games the bulk of the data is images or sound (or animations). It should be noted that .ogg is a compressed format, just like MP3.original_ninja wrote:i love battle of wesnoth. and i think the media is incredible, but i've noticed that the game images and sound take up almost 50% of the entire size of all game data.
I think this answers your questions, unless anyone has something to add?
Want to post a Wesnoth idea? Great! Read these:
Frequently Posted Ideas Thread
Giving your idea the best chance of acceptance
Frequently Posted Ideas Thread
Giving your idea the best chance of acceptance
I guess I would add that some packagers come out with a "Wesnoth lite" distribution, which leave out the superfluous graphics and sound.
Gif is better than Free; it's public domain. It's just not that good.turin wrote:The files are already compressed as much as they can be in the .png format. We don't use .gif, IIRC, because it isn't Free, so there are no Free graphics libraries that can display .gifs.
Hope springs eternal.
Wesnoth acronym guide.
Wesnoth acronym guide.
-
- Posts: 5
- Joined: April 24th, 2006, 12:37 am
- Location: Florida, USA
- Contact:
i took the liberty of doing a little test work, and i dropped the *.png image to 32,000 colors, and there was about a 15% gain, without any critical changes in quality. at 256 colors its about a 50% gain, but the quality is noticeably different. do we really need to use *.png at its fullest? i started this topic, because i use dial-up, but i like to stay up-to-date with wesnoth, and whenever a new version is released, the download is always quite large. and yes i've noticed that a few distro's have a "lite" version, with images of lesser quality. i manage a general purpose server, and among other things, it runs a wesnoth server, so downloading a binary and the source is almost triple the size of downloading a single binary, :-/.
As for 32,000 vs. truecolor...I have inadvertently implemented web site designs that broke in 16-bit color display from this. It was very difficult to fix. Technically, I don't think the risk is worth taking.
[restricting the colors worked in truecolor displays, but looked awful in 16-bit.]
"Critical difference" is often in the eye of the beholder. I'd rather trust trained eyes than mine...that is, the artists' eyes.
[restricting the colors worked in truecolor displays, but looked awful in 16-bit.]
"Critical difference" is often in the eye of the beholder. I'd rather trust trained eyes than mine...that is, the artists' eyes.
-
- Retired Terrain Art Director
- Posts: 1113
- Joined: November 29th, 2003, 11:40 pm
- Location: Norway
Yes.original_ninja wrote:do we really need to use *.png at its fullest?
Degrading the quality of any aspect of the game for everyone to cater to some minority of users will not be done, period.
Anyone has the freedom to distributed a trimmed down version of Wesnoth as long as they comply to the GPL.
And it's not even all about quality - using .png at it's fullest means that people can more easily work with the graphics directly (so they wouldn't need to download another "unoptimized" set to work with them). This is pretty important, since we have minor contributors who need to be able to just take the existing graphics and improve them easily. If the colour spaces for example are changed while optimizing, this would most likely result in all kinds of little colour errors in the long run when a lot of people would edit the images with different software, etc.
-
- Retired Developer
- Posts: 2633
- Joined: March 22nd, 2004, 11:22 pm
- Location: An Earl's Roadstead
Wow. I am surprised that sound and images only take up 50% of game data. Clearly we need to look into compressing the other data more.
"you can already do that with WML"
Fight Creeeping Biggerism!
http://www.wesnoth.org/forum/viewtopic. ... 760#131760
http://www.wesnoth.org/forum/viewtopic. ... 1358#11358
Translations! They're huge! 50% isn't accurate, though. I wonder if he took the size of the data directory as all data. It's mostly campaign images.Darth Fool wrote:Wow. I am surprised that sound and images only take up 50% of game data. Clearly we need to look into compressing the other data more.
Hope springs eternal.
Wesnoth acronym guide.
Wesnoth acronym guide.
- Casual User
- Posts: 475
- Joined: March 11th, 2005, 5:05 pm
May I ask where one may download "Wesnoth lite". I would be very interested.scott wrote:I guess I would add that some packagers come out with a "Wesnoth lite" distribution, which leave out the superfluous graphics and sound.
Not only would I be interested in a smaller download, but I have a slight aversion to any animation that is more than one frame long, so I would probably enjoy a Wesnoth where superfluous graphics have been removes.
Iwa is the only one still making the lite version (OS X). There used to be a wider selection of lite versions, but they weren't popular, so they quit making them. You would have to ask your packager to make one for you.
Hope springs eternal.
Wesnoth acronym guide.
Wesnoth acronym guide.
- Eleazar
- Retired Terrain Art Director
- Posts: 2481
- Joined: July 16th, 2004, 1:47 am
- Location: US Midwest
- Contact:
Exactly. This is, i believe one of the secrets of Wesnoth's success. No special tools or process is needed to work on the graphics. You just open up the images in a semi-decent editor and go. Images can be (and are) iterated hundreds of times with no loss of quality (other than human error). The artist is not required to install special graphics librarys or learn a new program. The gain to Wesnoth in attracting and keeping new artists well outweighs the extra megs spent on DLing.zookeeper wrote:And it's not even all about quality - using .png at it's fullest means that people can more easily work with the graphics directly (so they wouldn't need to download another "unoptimized" set to work with them). This is pretty important, since we have minor contributors who need to be able to just take the existing graphics and improve them easily. If the colour spaces for example are changed while optimizing, this would most likely result in all kinds of little colour errors in the long run when a lot of people would edit the images with different software, etc.
Since a disproportionate amount of the FOSS game art talent works on Wesnoth, i think we're doing a lot of things right.
Feel free to PM me if you start a new terrain oriented thread. It's easy for me to miss them among all the other art threads.
-> What i might be working on
Attempting Lucidity
-> What i might be working on
Attempting Lucidity