[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

How to bypass the Windows system palette for colorbanding (gradient colors)

Posted on 1997-05-31
1
Medium Priority
?
156 Views
Last Modified: 2010-04-06
In a D2 app. I present sampled data in trendcurves, using normal Delphi
routines like Canvas.MoveTo, Canvas.LineTo etc.
Now i'd like to extend the capabilities and plot the data as you sometimes
can see it in a wheather chart (all colors having gradients).
If I use the normal Delphi methods, the colors are rounded to the
NearestColor. That's not what I want since I know the video card is able to
display more precise colors.
Can anyone help me or explain it a little bit?
(Note: I already have digged into sourcecode of gradientform,
gradientcaption and gradientbutton, all found on DSP but that's not giving
the right solution).
Many thanks in advance.

0
Comment
Question by:elpeedee
[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
1 Comment
 
LVL 4

Accepted Solution

by:
StevenB earned 150 total points
ID: 1336699
 There are many solutions to the problem involving palette manipulation etc. however I suspect that the quickest solution for you will be this:

  If you use LineTo to generate the display output then you are using a Pen to generate the colour(color, are you un the US?). Pen colours are always rounded as you say to the nearest palette entry. If however you use a Brush to define the colour then the diplay will dither the colours for you as you are requesting. To use a Brush then you simply have to use the Rectangle command, for example, rather than a LineTo.

  Incidentally, in high colour mode the pen colours will be displayed correctly as the palette will have enough entries to accurately represent your output.

  Steven.
0

Featured Post

Important Lessons on Recovering from Petya

In their most recent webinar, Skyport Systems explores ways to isolate and protect critical databases to keep the core of your company safe from harm.

Question has a verified solution.

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

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
Objective: - This article will help user in how to convert their numeric value become words. How to use 1. You can copy this code in your Unit as function 2. than you can perform your function by type this code The Code   (CODE) The Im…
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …
In this video, Percona Solution Engineer Rick Golba discuss how (and why) you implement high availability in a database environment. To discuss how Percona Consulting can help with your design and architecture needs for your database and infrastr…
Suggested Courses

656 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