[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-games-devel
Subject:    Re: [Kde-games-devel] Re: new KDE game: dominoes
From:       "Troy Corbin Jr." <tcorbin () users ! sourceforge ! net>
Date:       2002-11-08 3:18:01
[Download RAW message or body]

On Thursday 07 November 2002 04:33 pm, Jay Glascoe wrote:
> hi,
>
> > How much space do the images take?
>
> a lot. There's three flavors: small, medium, large
> (24x48, 30x60, 36x72). Each consists of 120 images
> (a lot) which is 2 reliefs, 2 face downs, 4 direction
> arrows, and 112 domino faces (28 dominoes times 4
> rotations each).
>
> Uncompressed, each flavor takes up about 500k (I don't
> know whether this is funny or tragic... ;-)

Is each flavor just a different size, or are they actually different designs?

If it's size, you really only need the largest size you intend to support. 
Then, when loading your graphics resources, load them into QImage and perform 
a QImage::scale or QImage::smoothScale to reduce thier size.

Depending on several factors, this can be a slow process, so I wouldn't 
recommend resizing on the fly ( ie. whenever the window is resized ).

> The good news is that I haven't made any effort at all
> to reduce their size. Obviously, there's quite a few
> things I could do. PNG compression is easy, but doesn't
> really buy me much (2483 bytes to 2482 bytes... useless)
> Color reduction is easy (mogrify -colors 16 foo.png), it
> buys a much reduced size but at the price of loss of
> image quality. Loss of image quality is okay, but I would
> at least like to ensure that the resulting image looks
> just as good at 8 bit resolution as 24. This means
> selecting an adequate palette. And here we have entered
> the realm of "I have no idea what I'm doing!"
> (or, I do know how to use a palette: mogrify -map pal.gif
> foo.png, but *I don't know how to make one*)
>
> hmm. I don't know how to use the Gimp. I'd sort of like
> to learn, but graphics really isn't my thing. I'd rather
> spend my time learning, say, 3D programming (which I'm
> half stuck into now, really really really cool stuff)
> 95% of the time, xv and the ImageMagick suite are more
> than adequate for my image manipulation needs.
>
> It also occurs to me that maybe I'm being stupid in
> rotating the faces myself. In fact, I probably am being
> stupid. Can the Qt pixmaps be trusted to rotate themselves
> without information loss? Maybe. Hopefully. Let's see.
> I originally chose to rotate the images myself (with shell
> script calls to ImageMagick tools) due to lack of
> familiarity with C++ and lack of familiarity with Qt.

As I mentioned above, it's a speed tradeoff. Pre-rotated images are faster but 
bulkier. Or Qt can rotate them for you, but it will cause a slight speed 
penalty. Personally, I'd try the Qt rotation.

-- 
Troy Corbin Jr.
tcorbin@users.sf.net
http://knights.sf.net
_______________________________________________
kde-games-devel mailing list
kde-games-devel@mail.kde.org
http://mail.kde.org/mailman/listinfo/kde-games-devel
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic