JPEG graphics for large story images

Contribute art for mainline Wesnoth.

Moderator: Forum Moderators

Forum rules
Before posting critique in this forum, you must read the following thread:
scott
Posts: 5243
Joined: May 12th, 2004, 12:35 am
Location: San Pedro, CA

JPEG graphics for large story images

Post by scott »

I did a scan with omni disk sweeper, and I noticed our story images are large. 18 .pngs take up 6.6 MB out of approx 30 MB in resources. In order to get Liberty to upload to the forum (in the old days :) ) I had to convert the pngs to jpgs.

I converted the 5 biggest files and went from 2.3 MB down to 300k. Take a look and see if you can detect any loss in quality. I picked 85% quality as the lowest I could go before noticing sinc artifacts. The Green Isle picture ALREADY HAD filtering artifacts in png form, so I could have gone down to 50% but for the frame.

The best thing is that the HttT story pictures are already very blurred, and except for the frame these could easily go down to 40-50% before you notice anything. There's just no high frequency content in any of them. If there is positive response I will finish with the HttT pictures (at probably 65-75% quality for the frame's sake) and submit the set. If you could cut out 5 MB from the final product, I think it would be worth it to some people.

Edit: cut out some stuff that didn't apply and was wrong.
Hope springs eternal.
Wesnoth acronym guide.
User avatar
Jetrel
Posts: 7242
Joined: February 23rd, 2004, 3:36 am
Location: Midwest US

Post by Jetrel »

As long as there are no code/legal issues, I'm all for it.
I'd really like this to happen, just because it saves SO MUCH SPACE.
XJaPaN
Posts: 362
Joined: June 20th, 2004, 5:11 pm
Location: Germany
Contact:

Post by XJaPaN »

Good idea, the free space could be useful for future things to come.
charlieg
Posts: 209
Joined: December 16th, 2003, 8:41 pm
Location: Manchester, UK
Contact:

Post by charlieg »

XJaPaN wrote:Good idea, the free space could be useful for future things to come.
Especially in terms of web server load... ;)
Free Gamer - free games compendium & commentary
FreeGameDev - free game development community
Invisible Philosopher
Posts: 873
Joined: July 4th, 2004, 9:14 pm
Location: My imagination
Contact:

Post by Invisible Philosopher »

I agree this would be good too.
Play a Silver Mage in the Wesvoid campaign.
Mkgego
Posts: 436
Joined: April 15th, 2004, 10:26 pm
Location: Madrid , Spain , Europe

Post by Mkgego »

Yeah scott! Why taking png images if jpg has the same quality and it take up many less kbs than png files !!!
WoW C-Mode activated...
For the horde :D
scott
Posts: 5243
Joined: May 12th, 2004, 12:35 am
Location: San Pedro, CA

Post by scott »

The full set is available at http://www.cis.rit.edu/~slk8779/wesnoth ... ressed.zip

You be the judge.
Hope springs eternal.
Wesnoth acronym guide.
User avatar
ivanovic
Lord of Translations
Posts: 1149
Joined: September 28th, 2004, 10:10 pm
Location: Germany

Post by ivanovic »

Hi everyone!
I have taken a look at the picture. I tried to scale them a bit and found that the mission maps can get some probs when trying to scale them. Maybe it would make sense to leave at least this ones as they are. The story based images do scale very well and i can't really find a difference between the jpeg version and the png version. But beside i do NOT know how much problems it could make to implement another lib into the game. At the moment the game does not depend on the jpeg-lib. If jpeg-pictures would be integrated there would be another dependency.
But maybe the devs take a look at it and it is hopefully possible to include the support without too many probs.
CU
Nils Kneuper aka Ivanovic
Invisible Philosopher
Posts: 873
Joined: July 4th, 2004, 9:14 pm
Location: My imagination
Contact:

Post by Invisible Philosopher »

ivanovic wrote:Hi everyone!
I have taken a look at the picture. I tried to scale them a bit and found that the mission maps can get some probs when trying to scale them. Maybe it would make sense to leave at least this ones as they are. The story based images do scale very well and i can't really find a difference between the jpeg version and the png version.
Leave the original PNG available elsewhere.
ivanovic wrote:But beside i do NOT know how much problems it could make to implement another lib into the game. At the moment the game does not depend on the jpeg-lib. If jpeg-pictures would be integrated there would be another dependency.
SDL_Image can (and does) already handle JPEG. I use it in my campaign, as do others in theirs.
Play a Silver Mage in the Wesvoid campaign.
User avatar
Jetrel
Posts: 7242
Joined: February 23rd, 2004, 3:36 am
Location: Midwest US

Post by Jetrel »

Invisible Philosopher wrote:
ivanovic wrote:Hi everyone!
I have taken a look at the picture. I tried to scale them a bit and found that the mission maps can get some probs when trying to scale them. Maybe it would make sense to leave at least this ones as they are. The story based images do scale very well and i can't really find a difference between the jpeg version and the png version.
Leave the original PNG available elsewhere.
he meant how we have many, many resolutions supported by wesnoth, and yet in all of them, the story screens fill the monitor (IIRC). Such scaling with a png looks fine, such scaling with a jpen can go to hell in a handbasket, do to the way it compresses stuff.


That said, this is starting to look rather promising.
Invisible Philosopher
Posts: 873
Joined: July 4th, 2004, 9:14 pm
Location: My imagination
Contact:

Post by Invisible Philosopher »

Jetryl wrote:he meant how we have many, many resolutions supported by wesnoth, and yet in all of them, the story screens fill the monitor (IIRC).
That is not true. I tested with lots of different wesnoth screen sizes to make sure. Wesnoth does *not* scale story images.
Play a Silver Mage in the Wesvoid campaign.
scott
Posts: 5243
Joined: May 12th, 2004, 12:35 am
Location: San Pedro, CA

Post by scott »

Both jpeg and png are bitmap graphics. Once uncompressed, they should scale the same way, as far as I know. There isn't any more information in a displayed png than there is in a displayed jpeg. Jpeg compression cuts out contrast (quality) not resolution (quantity).
Hope springs eternal.
Wesnoth acronym guide.
User avatar
Ankka
Posts: 594
Joined: January 2nd, 2005, 2:40 pm
Location: Finland

Post by Ankka »

Invisible Philosopher wrote:
Jetryl wrote:he meant how we have many, many resolutions supported by wesnoth, and yet in all of them, the story screens fill the monitor (IIRC).
That is not true. I tested with lots of different wesnoth screen sizes to make sure. Wesnoth does *not* scale story images.
Nor the game itself... the only thing I've noticed have been scaled is the minimap( or was it?) and the "observers"-sign in the up left corner in multiplayer... basicly everything else is the same as in full screen mode.
User avatar
Elvish_Pillager
Posts: 8137
Joined: May 28th, 2004, 10:21 am
Location: Everywhere you think, nowhere you can possibly imagine.
Contact:

Post by Elvish_Pillager »

Ankka wrote:That is not true. I tested with lots of different wesnoth screen sizes to make sure. Wesnoth does *not* scale story images.
Nor the game itself... the only thing I've noticed have been scaled is the minimap( or was it?) and the "observers"-sign in the up left corner in multiplayer... basicly everything else is the same as in full screen mode.[/quote]

It also scales the main display if you use the zoom in/out keys.

I find them more annoying than useful, and eliminated the hotkeys.
It's all fun and games until someone loses a lawsuit. Oh, and by the way, sending me private messages won't work. :/ If you must contact me, there's an e-mail address listed on the website in my profile.
tuppe666
Posts: 20
Joined: November 25th, 2004, 7:36 pm

Post by tuppe666 »

Just out of interest I ran AdvancePNG.

Code: Select all

 for i in *.png; do advpng -z4 "$i" ;done
Just to see what saving could be made leaving them png.

The images directory drops from 22419456 bytes to 21866496. Not to be sniffed at and nothing needs to change.

Code: Select all

find . -name '*.png' | while read i; do optipng -o7 "$i"; done
optipng drops it to 21632000 saving a meg nice
Last edited by tuppe666 on February 3rd, 2005, 12:50 am, edited 1 time in total.
Post Reply