Solved

TGifImage (Melanders) - how to set best quality for bitmap to gif conversion

Posted on 2006-06-13
3
638 Views
Last Modified: 2013-11-19
Hi I'm using Melanders TGifImage (on D2005) and assigning a bitmap to a gif but the resulting gif just looks 'orrible. In the GifImage unit it says the default settings are the fastest but worst - does anybody know which settings give the best conversion results please? (Don't care about the speed at all just the quality). Sorry I know nothing but the basics for graphics!
Thanks
P

from code:
//: Default color reduction methods for bitmap import.
  // These are the fastest settings, but also the ones that gives the
  // worst result (in most cases).
  GIFImageDefaultColorReduction: TColorReduction = rmNetscape;
  GIFImageDefaultColorReductionBits: integer = 8; // Range 3 - 8
  GIFImageDefaultDitherMode: TDitherMode = dmNearest;

  //: Default encoder compression method.
  GIFImageDefaultCompression: TGIFCompression = gcLZW;

  //: Default painter thread priority
  GIFImageDefaultThreadPriority: TThreadPriority = tpNormal;

  //: Default animation speed in % of normal speed (range 0 - 1000)
  GIFImageDefaultAnimationSpeed: integer = 100;

  // DoAutoDither is set to True in the initializaion section if the desktop DC
  // supports 256 colors or less.
  // It can be modified in your application to disable/enable Auto Dithering
  DoAutoDither: boolean = False;
0
Comment
Question by:Pandora
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 34

Accepted Solution

by:
Slick812 earned 500 total points
ID: 16899558
if you are reducing a 24 bit muticolor bitmap (photo Image) to 8 bit in the TGif Image you might try and set the image color reductions to -

  GIFImageDefaultColorReduction  to  rmQuantize // or  rmQuantizeWindows for standatd color inclusion
 
  GIFImageDefaultDitherMode   to  dmFloydSteinberg  // dmBurkes is also good, and the others give various results depending on the image

  DoAutoDither  to True

but the

TColorReduction = rmNetscape
and
TDitherMode = dmNearest;

do NOT give pleasing results for photographic images

you should read the help files for TGIFImage, I beleive it has some about this
0
 
LVL 34

Expert Comment

by:Slick812
ID: 16899679
also, the color reduction settings are mutiple, not just one setting offered, so each setting has a use, depending on what image you start with and what GIF image you want to end with, so you may just experiment with the various settings to see which ones are best suited for your input image and your technical requirements (or maybe visual requirements) for your Gif file, ,  Each of the different TDitherMode settings has a slightly different rendering for closely matched colors like a color gradient, , as to which looks best? but that visulal judgement is up to the viewer
0
 
LVL 1

Author Comment

by:Pandora
ID: 16901181
ooh thats much better! Thanks slick, :)
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
AutoCad licenses 9 89
Dev express lookupcombo 3 45
enhance the following code 3 42
Problem working with dynamic array - help 2 35
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
Technology opened people to different means of presenting information, but PowerPoint remains to be above competition. Know why PPT still works today.
In this Micro Tutorial viewers will learn how to remove an unwanted object using Photoshop’s feature known as content-aware fill.
Learn how to use the remote presentation tool in Prezi to allow you to harness the power of this cloud based presentation platform. You can show your presentation with a remote audience using this free tool.

749 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question