If I just add the watermark (which is a png with transparency also), the transparency works.
If I just add the text, it renders text but converts all transparency to white.
If I add text and watermark (any order), text and watermark are shown but all transparency is converted to white.

Any ideas would be great! I have tried to fix this longer than I would like to acknowledge. I tried 5 pr 6 different PNG formats from photoshop using various export methods and settings. I also tried to fix the image in RIOT image optimizer. I also tried changing the order of commands. I also tried green gif and setting green as transparent before the rest and that didnt work either - although I prefer PNG with alpha anyway. I also tried maybe 20 variants of different transparency settings in nconvert.

** I wanted to add that these same source files and tasks do work in xnconvert, that do not work in nconvert. Even using the exported script. But I really wish for nconvert to be the tool.

I don't have much experience with transparency, and XnTriq who is the expert doesn't normally post on NConvert issues and in any case hasn't been posting much recently, so while waiting for Pierre to respond, if he does, it might help if you could:

o Upload a simple test image transparency.png

o Upload a simple test watermark file watermark.png

o Reduce your code to the absolute minimum terms required to illustrate the problem, remembering that arguments will normally have default values, and you probably don't need to rotate the text, for example, to reproduce the issue. You to some extent also present the issue as two problems but writing text on the transparent source image is likely the real problem, isn't it?

In passing and probably not relevant, I notice that XnConvert has a text opacity value, and I don't see a way of setting that in the NConvert help file??

It does look like a possible NConvert bug, and reducing the issue to the minimum required to reproduce it could help motivate Pierre, or anyone else, to investigate it...

I've taken the liberty of editing your previous post slightly to add more space between the images you uploaded, so that the headings relate more clearly to the relevant image, I hope. Your 256px image above is also 180px, I believe.

I have done some tests of my own using your watermark and source transparency files: the results are confusing because I was unable to write text onto a transparent file, whether or not the watermark had been applied, and the image remained transparent rather than being changed to white.

After experimenting a bit, I reduced your problem to the following code, which uses my own file names:

Thanks for the edit and upload. This is funny a little. I used the files you provided and this time the words were partially written over top the watermark. Not on the fully trapsparent pixels, but only where the watermark and its shadow were.

Strange how the text doesn't provide its own (pixel to pixel opaque & transparent ) backing adjusted only by text transparency. Im not sure if this is a bug or a known limitation. And like you, XNconvert handles fully transparent starting files perfectly in my experience.

So heres some red backgrounds. 25% transparent is good. And text DOES write to it with the watermark and without. But its transparency matches the background. And it changes the transparency of the watermark.

So the same problem still but a bit different. I can write to a semi-transparent background, but its matching transparency make it unusable. I tried to write text over the faint result image, hoping the darkness of the text would build up after 4 layers to 100% but it didn't.

...Can XNconvert be run in command line?
...Is it possible to generate some sort of negative mask of the text where transparency is only at the rasterized text for a perfect fit? And then use that overtop any solid color opaque background to make your own transparent images. Impractical compared to the ease of this task in xnconvert, but is that what it would take? XNconverts text is might clean looking and nothing like the color keyed text I have seen also.
...can I make a opaque 1 color image transparent in nconvert and write to that result? What if the text has a opaque backing then. I don't know the code for that. Im not really sure where to go from here without getting too far from the manual.

This continues to be very confusing, with your results using the same source files in some respects seeming different to my results.

I think the way forward is to keep the issue as simple as possible:

XnConvert produces the expected result, NConvert does not...

I suggest you post new image and watermark test files, with those names, and in a ZIP to ensure that they cannot possibly be modified in any way when uploaded, together with your XnConvert result and your minimal NConvert code. Then Pierre should be able to easily reproduce the issue and investigate any confirmed bug.

Edit:

If the issue can in fact be reproduced with just a transparent source image, without applying the watermark, you may as well reduce the issue to that and post just what is needed...

Edit 2:

I have confirmed that NConvert does NOT write text to the above transparent image.png, no need to add a watermark, whereas XnConvert does.

I have been trying to prepare a new post but my attachments uploaded to the forum keep vanishing from the draft for an unexplained reason.