سؤال

It looks like merged-image-data in PSD files contains RGB data which is blended with white color (based on transparency). Is that correct for all versions of Photoshop/PSD? Can I disable it or control that color?

The context: I'm reading PSD file using C++ code (although no coding knowledge is necessary to answer the question I believe). PSD files contain merged data of all layers in "Image Data Section" (RGB, transparency (if any) and then alpha masks). From my experience it looks like that RGB data is premultiplied with White color based on transparency. This causes problems when you want to blend that RGB with something based on transparency (think: I used that data as a texture in game engine). I attached image illustrating the problem. The top image is source in PhotoShop. The bottom left shows RGB in merged data - see transparent image parts are blended with white. My goal is to get RGB data from all layers without that white-blend, i.e. image on the bottom-right (only fully transparent parts are filled with white color).

enter image description here

Simply open transparent PSD file in any tool that ignores layers (IrfanView for example) and you will see that image is premultiplied with white.

Formats like PNG support color in transparent image parts - no blending with white (or other color) is done.

So my question: do I have any control over that blend-with-white? Do all PhotoShop version do that?

هل كانت مفيدة؟

المحلول 2

You have no control over this. Photoshop always merges layers with white color.

What we ended up doing is subtracting that while color based on alpha value during import of PSD file into our engine.

نصائح أخرى

If I understand your question correctly, it sounds like you may have merged your layer with the white default background. Photoshop blends the image with the colors around it by default, so if there's the white around the image you're blending, then yes, it will blend white, and this is true for all versions of Photoshop.

You should have what you want to blur on it's own layer and then try again.

EDIT: Aw ok. Well what it's putting out is what it's suppose to put out. I'm assuming you're using the Gaussian blur, if you are, it's doing exactly what it should. To get to what you expect, you can't use the blur tool alone. Some of the shapes are sharper then others and some are more blurred then others. Since Gaussian blur sets a uniform blur over everything, so it's impossible to expect Photoshop to do what you want it to in one simple action (but you can make your own action if you want to do this action multiple times).

To get from point A to point B, I suggest putting each line on it's own layer to start, and then use the smudge tool and blur tool to get the lines how you want them. Here is and example of the smudge tool:

enter image description here

You may want to make the hardness of your brush 100% instead of 0% for the more sharp lines. It's hard for Photoshop to make a complete blurred line completely sharpened like you're asking it to. But you can still use a blurry line. For the more bumpy lines you want to do, you can use the Magic Wand tool to select your soft brush strokes and then fill them in with the Paint Bucket tool to get the effect you're looking for (before and after):

enter image description here

Again, Photoshop doesn't have a built in action to do what you want. All of it's built in functions do a universal effect to the whole image, and this is true for all versions of Photoshop, but it's very easy to get the effect you want to. Make sure everything is on it's own layer and experiment with the tools Photoshop has available.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top