Solved

Setting 0-255 RGB Intensity in a 256 Color Palette

Posted on 1997-06-21
2
610 Views
Last Modified: 2012-08-14
Hello,
I am an amateur C/C++ programmer currently programming for Dos in MSVC 1.52 without MFC support.
I would like to know of a way to remap a 256-color screen palette, so that each color is composed of a RGB triplet.
However, the way that I found to do this only allows to set a 0-63 value for each RGB component.
What procedure do I need to use in order to be able to set each RGB component in a range of 0-255?

Thanks in advance to anyone who helps me out,
Sincerely,
EnigMasterMind.
0
Comment
Question by:enigmastermind
[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 Comments
 
LVL 4

Accepted Solution

by:
AVaulin earned 50 total points
ID: 1164013
You must change current palette. The easiest way to do this is using some libraries which allows to do this. For example PCX Toolkit by Genus Microprograming Co. Also this toolkit allow to do many useful things for graphics in DOS.
Try and good luck.
0
 
LVL 1

Expert Comment

by:mosfet
ID: 1164014
The reason you can't find a way to have an RGB value of 0-255 in 256 color mode is because there isn't one. RGB values of 0-63 define 256 colors. RGB values of 0-255 define Truecolor 16.7 million colors. Of course this is going to be SVGA.
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Ready to improve network connectivity? Watch this webinar to learn how SD-WANs and a one-click instant connect tool can boost provisions, deployment, and management of your cloud connection.

Question has a verified solution.

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

IntroductionThis article is the second in a three part article series on the Visual Studio 2008 Debugger.  It provides tips in setting and using breakpoints. If not familiar with this debugger, you can find a basic introduction in the EE article loc…
C++ Properties One feature missing from standard C++ that you will find in many other Object Oriented Programming languages is something called a Property (http://www.experts-exchange.com/Programming/Languages/CPP/A_3912-Object-Properties-in-C.ht…
The goal of the video will be to teach the user the difference and consequence of passing data by value vs passing data by reference in C++. An example of passing data by value as well as an example of passing data by reference will be be given. Bot…
The viewer will be introduced to the member functions push_back and pop_back of the vector class. The video will teach the difference between the two as well as how to use each one along with its functionality.

632 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