Once I wanted to save the background graphic of a game. So, I had to do two screenshots. Since the player sprite covers a part of the background, I cut this part out of the second image and pasted it on the first image. Like this:
+
=
Then, when the part of the second image was pasted on the first image, I noticed something: The colors were not 100% identical. The first screenshot used another palette as the second screenshot. Both time it was the same emulator and I didn't choose another .pal file either. The differences were not visible right away. Only when I pasted a part of the second image on the first, I saw that all the colors were a nuance different.
I did that on my mother's PC. It never happens on my own. On my PC, the colors are always consistent. But on my mother's, the palette may change from screenshot to screenshot.
Now my question: How is that possible?
Maybe the bit-depth the desktop uses makes a difference?
Maybe the images are being saved/generated as JPEGs or some other lossy format which results in quality loss every time you re-save them?
tokumaru wrote:
Maybe the bit-depth the desktop uses makes a difference?
Even if this was the case, both images should still look the same since it would still be the same desktop where they are created. (But, no, it was 32 bit.)
koitsu wrote:
Maybe the images are being saved/generated as JPEGs or some other lossy format which results in quality loss every time you re-save them?
No. The images in FCE Ultra are saved as PNG. And during my editing work, I copy them to MS Paint and save them as simple BMP files.
And as I said: It's something that never ever happens on my own PC, but happened the instant I tried to paste images together on the other PC. So, it can't have anything to do with my working techniques.
Are the 3 images you're working with literally those in the first post? Because the first image is a JPEG, the 2nd and 3rd are PNG.
EDIT: Nevermind, the first image is actually a PNG but the file extension is wrong.
EDIT #2: What part of image #3 has a slightly different palette? I'm looking at the palette compared to images #1 and #2, and I don't see anything that's different.
koitsu wrote:
Are the 3 images you're working with literally those in the first post?
[...]
EDIT #2: What part of image #3 has a slightly different palette? I'm looking at the palette compared to images #1 and #2, and I don't see anything that's different.
No, the three images are just an example to explain what I mean with pasting two images together. These pictures all have the same palette since I'm on my own PC and there the palette is always correct. I can't recreate the actual error now because my mother's PC is not available to me in the moment.
koitsu wrote:
Because the first image is a JPEG, the 2nd and 3rd are PNG.
EDIT: Nevermind, the first image is actually a PNG but the file extension is wrong.
In this case it's an error of Tinypic. All of them were PNGs and had the correct file extension when I uploaded them.
I assume that the error has something to do with the graphic card. Could this be possible?
I can't say yes or no until I see actual examples. :-)
Well, what do you want to see there? Just imagine a screenshot where all the colors are for example three numbers lower for red, green and blue. So, orange, which has usually the RGB value 200, 76, 12 in FCE Ultra would be 197, 73, 9. Something like that.
I can't explain why taking two screen shots within the same running instance of an emulator would result in different palettes. The only explanations I have would be a lossy file format, or if the comparison is between what you see on-screen vs. what gets written to disk in the PNG.
koitsu wrote:
I can't explain why taking two screen shots within the same running instance of an emulator would result in different palettes. The only explanations I have would be a lossy file format, or if the comparison is between what you see on-screen vs. what gets written to disk in the PNG.
- Did you try another emulator? o.O
JohnJohn wrote:
No. The images in FCE Ultra are saved as PNG. And during my editing work, I copy them to MS Paint and save them as simple BMP files.
Some MS programs used to have difficulties with PNG files. Older versions of Internet Explorer come to mind. They displayed PNGs a tad darker than they're supposed to be. Never heard of Paint messing up the colors, though.
What version of FCE Ultra are you using?
koitsu wrote:
I can't explain why taking two screen shots within the same running instance of an emulator would result in different palettes.
Me neither.
koitsu wrote:
The only explanations I have would be a lossy file format, or if the comparison is between what you see on-screen vs. what gets written to disk in the PNG.
Cannot be the case either. A difference between screen output and PNG screenshot is not important since the two images with the different palette are both PNG screenshots. (This would only be relevant if I had made one screenshot with the screenshot function of the emulator while the other screenshot was made with the "Print" button on the keyboard.)
miau wrote:
Some MS programs used to have difficulties with PNG files. Older versions of Internet Explorer come to mind. They displayed PNGs a tad darker than they're supposed to be. Never heard of Paint messing up the colors, though.
By the way, I don't open the PNG file with Paint. I open the PNG file with Microsoft Photo Editor from Word 97. Then, I right-click and copy the image to the clipboard. Then I paste this to a standard 24 bit BMP file in Paint.
miau wrote:
What version of FCE Ultra are you using?
FCE Ultra 0.98.12. But it can't have to do with the emulator, I think. As I said: I worked on two computers. Everything was the same: Same emulator with same palette (FCE Ultra 0.98.12 with default palette), same game ("Castlevania (U) (PRG0).nes"), same screen resolution (800 x 600, 32 bit), same operation system (Windows 98 SE (the PCs are very old)), same program to open the PNG files and to copy the image to the clipboard (Microsoft Photo Editor from Word 97), same program to edit the images (Paint). And the result: My computer always has the same colors for the images, and I edited tons of them. The other computer had a color difference and I recognized it after only six screenshots.
It seems like the image travels a lot until it finally reaches its destination, so if I were you I'd try to identify exactly when the colors get messed up. If you open the PNG directly in MSPaint, or use different combinations of software you might detect which software is the guilty one.
It isn't the software. If it was the software, the error would occur on my PC as well since I always use exactly the same software on the same operation system. Also, even if one of the progams messes up the colors, wouldn't it mess up the colors in every image equally?
I'm still assuming that the graphic card is guilty of it, maybe changing the colors a bit with each restart of the emulator.
Sometimes a DirectX or OpenGL window can change depending on whether a menu or tooltip is on top of it.
I'd suspect 16 bit color mode.
JohnJohn wrote:
It isn't the software. If it was the software, the error would occur on my PC as well since I always use exactly the same software on the same operation system.
I don't know what you expect us to say then... "It's your mother's PC's fault, throw it out the window!"? If you want to find the reason for this you have to debug the problem, regardless of how certain things are not likely to be the problem. We don't have access to your computers, so you are the only one who can debug this.
Dwedit wrote:
I'd suspect 16 bit color mode.
He says both computers are set to 32-bit.
Looked more to me like one application clamping the RGB values to the traditional VGA 0-63 range vs the 0-255 range.
Dwedit wrote:
Looked more to me like one application clamping the RGB values to the traditional VGA 0-63 range vs the 0-255 range.
You have a build of FCEUX which runs in DOS using mode 13h, 320x200x256 @ 18-bit colour? :-)
If it's RockNES, then indexed color modes in the Allegro library still use 6-bit component values.
tepples wrote:
If it's RockNES, then indexed color modes in the Allegro library still use 6-bit component values.
- Nope, do you mean 00-3F? It's quite old! ^_^;;
nes_palette[ index ] =
makecol32(red,green,blue);
//red,green or blue range is 00-FF.
tepples wrote:
Sometimes a DirectX or OpenGL window can change depending on whether a menu or tooltip is on top of it.
Really? Also the colors?
Dwedit wrote:
I'd suspect 16 bit color mode.
No. 32.
tokumaru wrote:
I don't know what you expect us to say then... "It's your mother's PC's fault, throw it out the window!"?
Well, I hope that someone who knows about hardware can maybe confirm me that it's the graphic card or whatever.
tokumaru wrote:
If you want to find the reason for this you have to debug the problem, regardless of how certain things are not likely to be the problem. We don't have access to your computers, so you are the only one who can debug this.
As I said, the software is the same on both PCs, so if the Photo Editor mixed up the colors, it would do on both PCs. The only variable is the graphic card.
JohnJohn wrote:
As I said, the software is the same on both PCs, so if the Photo Editor mixed up the colors, it would do on both PCs. The only variable is the graphic card.
OK, but wouldn't you still like to know which software is having problems with the video card? It might be the photo editor, not the emulator, who knows?
Hm. But I assume that the Photo Editor uses GDI, the simple graphics output library. The emulator on the other hand uses the hardware-near DirectX, taking full advantage of the graphic card. And there's already a visible difference: When choosing a 2x2 windowed screen size in FCE Ultra, my own graphic card just resizes the screen as simple "nearest neighbour". My mother's more recent graphic card uses bilinear filter. If I want nearest neighbour resizing there, I need to disable hardware acceleration. So, if there is a program that works differently on different graphic cards while otherwise retaining the same options, it's most probably the DirectX application with its direct access to hardware, not the plain old WinAPI GDI application with its device independent BitBlt stuff.
Most emulator allow you to set your video mode to GDI, which should fix your issue if the video card is the cause. But by looking at some versions (...) of FCE, some may allow it, others don't so you could be out of luck. If your version that you're using doesn't support it, try another emulator that support GDI and see if you have the same result, that's what I would do. If GDI is not specified directly usually it "disable hardware acceleration" or something related to video memory, just forgot what they usually say. If after that it doesn't fix your issue, there's not much we can do without being in front of those machine.
I guess that all we can recommend in this case then is that you try another emulator (just like in the "Star Wars (E)" thread).
Since it's not really a practical problem of mine (as I said, it works fine on my PC), I'm more interested in finding out what causes the problem out of curiosity instead of finding an alternative. Trying another emulator would be fine if I had actual trouble with it. But it's something I just realized some time ago. And now I'm interested in an explanation. That's why I hope that someone maybe experienced it himself or can give a definite explanation.
P.S.: No, FCE Ultra doesn't have a mode to change to GDI.
Sorry if I will be rude but if you don't try to test what we say, there is not much we can do. By "try another emulator" we didn't mean to change the emulator: we said to try another emulator to see if you will have the same results. That other emulator must at the least support GDI. From there, that should help you figure out if it's a direct-x/GDI issue. Without experiment you will not be able to guess the cause of the issue. From only what you said, you can only guess it could be direct-x but without testing it you will not figure it out.
- Meh. What is the image editor you're using for? Next, how are you merging the images? Do you overlap them? Do you save, then load a image? It might be the quality setting (if JPEG).
- When I want to reduce the quality (for file size reasons), I use MS Paint. Otherwise, another editor. As far as I can tell you, two screenshots should have the exact same color.
Zepper wrote:
- Meh. What is the image editor you're using for? Next, how are you merging the images? Do you overlap them? Do you save, then load a image? It might be the quality setting (if JPEG).
- When I want to reduce the quality (for file size reasons), I use MS Paint. Otherwise, another editor. As far as I can tell you, two screenshots should have the exact same color.
We determined he's using PNG, so JPEG compression (quality settings) shouldn't apply. But we'd need to see actual captured images (the PNGs) to determine what's going on.
I declare this the most boring thread of all time.
thefox wrote:
I declare this the most boring thread of all time.
http://icanhascheezburger.com/2007/06/2 ... -business/