Hi, I'm trying to obtain the number of colors and possibly the color
table of png files. However, most of my files are RGB (not palette)
mode. Does anyone know how to obtain those info?
I am using the png.h library. I have tried using the png_set_dither
function to convert the rgb mode to palette mode, but did not succeed.
(I would prefer to be able to directly get the info from RGB mode
though.)
Thanks, much appreciated. 1 3693
floobles wrote: Hi, I'm trying to obtain the number of colors and possibly the color table of png files. However, most of my files are RGB (not palette) mode. Does anyone know how to obtain those info?
Have you tried searching the web for the formats of PNG files? http://www.wotsit.org
I am using the png.h library. I have tried using the png_set_dither function to convert the rgb mode to palette mode, but did not succeed. (I would prefer to be able to directly get the info from RGB mode though.)
Thanks, much appreciated.
Perhaps some people in a graphics group or a group about
your platform could be of better assistance. In this
newsgroup, news:comp.lang. c++, we discuss issues with the
language, not applications of the language. The language
does not have facilities for graphics or file formats,
so we don't discuss those topics here.
Read the FAQ and Welcome.txt below.
--
Thomas Matthews
C++ newsgroup welcome message: http://www.slack.net/~shiva/welcome.txt
C++ Faq: http://www.parashift.com/c++-faq-lite
C Faq: http://www.eskimo.com/~scs/c-faq/top.html
alt.comp.lang.l earn.c-c++ faq: http://www.comeaucomputing.com/learn/faq/
Other sites: http://www.josuttis.com -- C++ STL Library book This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Rich |
last post by:
I need to change my form's backcolor back to the design color after it
changes to
another system.Drawing.Color. In the backcolor design, the value is in RGB
me.BackColor = ...RGB(255, 255, 192)
This doesn't work. How can I change the RGB values to System.Drawing.Color?
Thanks
|
by: Sugapablo |
last post by:
Take a look at this page if you will:
http://www.sugapablo.net/temp/colortest.html
Does it look right to you? Should #0000ff and #000fff be the same shade
of blue? Especially since #ff0000 is red and #fff000 is drastically
different as yellow.
Maybe my monitor is busted or something?
Does anyone else find this strange? That the RGB levels would be
|
by: teresni |
last post by:
We've got some JavaScript code that gets the current background color.
It works, but Netscape returns it in rgb format, while IE returns it as
the color
text name (e.g., 'white'). We need to do some math calculations on the
color,
so I want the rgb values. How can I get IE to return the background
color in rgb
format, or how do I convert the text color to its rgb value? Thanks!
|
by: julian_m |
last post by:
Do anyone know an algorithm which retieves a grey value given certain
rgb value?
I'm needing this kind of function:
$grey = RGBtoGrey('#ffffff');
where $grey (function's return value) should be a real number in
range
|
by: anuragkhanna8 |
last post by:
Hi,
I am trying to convert a 16 bit rgb value to 32 bit, however the new
color generated is different from the 16 bit rgb data. Please let me
know the formula to convert an 16 bit rgb data to 32 bit rgb data.
Thanks!!
| |
by: surf |
last post by:
I found a javasript program on the web, it has the following call to
rgb() which is not in my javascript manual. What is it and what is the
+red+ notation ?
this.span.childNodes.style.color="rgb("+red+", "+grn+", "+blu+")";
|
by: samadams_2006 |
last post by:
Hello,
There are various "Color Pickers" out there, where a series of colors
are displayed on a grid and when the user clicks one of these colors,
it is selected, and processed by the application. NOW THE QUESTION:
Is there an easy way to do this in the opposite direction? For
example, what if you have a photographic image and would like to
determine the RGB values of a certain section of the photograph?
|
by: fallen angel |
last post by:
halu there!! i'm a 1month experienced java scripter but got a good hang of it already. hehehe.. i developed a "color selection" tool, similar to the one in flash when you choose a color for a graphic, with CSS only. the product is finished. whenever i select a color, its color will be displayed in a box whose id name is contained in variable "color_box" and the equivalent color value will appear in a text box with id contained in the variable...
|
by: =?Utf-8?B?R3JlZw==?= |
last post by:
I'm using VB 2005.
When I select a color from the properties window for a control, it returns
an RGB color code (255,255,255). Now, when I attempt to assign a color in
code it is done using the COLOR.COLOROPTION value. How can I take an RGB
color set in the properties window and assign it via code. For example, I
have a control who's color is (192,255,192). I want to be able to also assign
this exact same color via code using the...
|
by: cjlopesmartins |
last post by:
Hi
Please help
I have this mysql table field with a RGB value like 120-10-200 and I
nead this php function to convert this value into html color
#??????
Thanks in advance
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
| |
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
| |
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |