Baffled: getting a black box around what should be masked out


https://forum.reallusion.com/Topic458412.aspx
Print Topic | Close Window

By esemgee - 5 Years Ago
I have had no problems doing this in the past, 'this' being adding a label to an object - a beer bottle to be precise. No matter what I do the shaped logo (it is not a square) still has a black surround to it. The bottle shape is from sometime back and was a freebie on the Marketplace, but that should not be the problem - should it? 
By mark - 5 Years Ago
Is the image map you are using a .png?
By Lord Ashes - 5 Years Ago
You either need to use a PNG file (with the transparent portions being transparent) or you need to set an appropriate opacity.

Using a PNG file will cause the alpha channel (the info about what is transparent) to automatically generate an appropriate Opacity file.
Using other files formats (like JPG or BMP) will require you to create a corresponding Opacity file (pure black where it should be fully transparent and fully white where it should be fully opaque). 
By Amper Sand - 5 Years Ago
Me I had the following tricky issue :)
I had a prop and I wanted to edit only the Diffuse image, which was a JPG - so I saved it, I edited it, then I dragged it back into the Diffuse. But something somehow looked different: looking carefully, I observed that when I dropped it, iClone automatically replaced the old Opacity with a new one, auto-generated from the modified Diffuse, which was fully opaque so what should have been transparent become black. So, I redo the whole process, but I also saved the original Opacity image; after dragging the new Diffuse, i also dragged the old Opacity and everything went OK.
By esemgee - 5 Years Ago
@amperfox, @Lord Ashes and @mark. Thanks for your responses. The original image I am using to replace the label is png, and after a slight tweak in Photoshop was saved as png - I have also tried it using jpg with a mask. The png created its own opacity file. Now, everything TELLS me it is png but if I use the opacity the image goes, leaving a black or opaque square. This would appear to be a ghost of the label I am replacing. If I delete the label then the bottle has a totally see-through square, so somehow the bottle was made with this square in it (??Why??), yet I can see no method of how the bottle was made, how to fill this square in etc. So, basically, I am putting on the label correctly, your help confirmed it, but now there is this oddity of a square that should not be there!

Something else that is strange: as far as I can find out this is the ONLY beer bottle in the whole of RL Marketplace. It is free (beer bottle with top) so if you want to have look at it please let me know if there is a way round the problem.
By esemgee - 5 Years Ago
I have given up, spending too much time trying to solve it - obviously the creators of this (bottle and cap) were learning! There are more bottles after all and what I wanted worked reasonably easily - just some resizing.  Thanks for your help, and, if you ever get bored, there is a little puzzle for you...
By justaviking - 5 Years Ago
Reaching way back into the dusty archives of my brain...

Several years ago I struggled with some lettering similar to what the OP described there.  Eventually I found out my "black" background was not pure black.  What should have been 0,0,0 (RGB) was something like 0,2,0.  I had used a color wheel or something like it to pick the black background, and my mouse must have slipped away from the pure-black corner.

Sorry I can't recall more details than that, but it's one more area to investigate.
By mark - 5 Years Ago
Might be nice to see a screen shot of the issue as well.;)
By Postfrosch - 5 Years Ago
Hi Garry,
look this Clip. It works fine with jpg-File

Take no png-File.
Greets Postfrosch

By thebiz.movies - 5 Years Ago
Hi Garry, just saw this post this morning.  As postfrosch shows the image can be easily changed (at least in my case). The original file was a jpg and had no opacity map.   If you want to remove the label simply use the paint material tool and apply the bottle texture to the label areas.  Please post an image of the black box and perhaps someone can figure this out.

Heres the asset if anyone wants to take a look: https://marketplace.reallusion.com/bottlecap
By esemgee - 5 Years Ago
@thebiz.movies and @Postfrosch. Thanks so much for your time in this, it is genuine help and I appreciate it enormously, however, you rather missed what I was trying to do: A smaller, shaped label - not just replacing the one that was there - on a see-through beer bottle, with a 'blurb' label on reverse and a circular one on neck.  What I want I can do with other bottles, no problem, just this particular one, as it was free, became a challenge. The bottle is the error, not what I (and everyone offering support) was doing, which is 100% correct.

I would suggest you save your time but if you want to try again I have attached the original image I used for the label.  I have also enclosed a photo of the offending bottle with their label deleted - note there is a white square instead, this should just be 'glass' and I presume is the reason for the error. Alongside is what I wanted, but with a better designed prop, so I am ready to go. Again: thanks everybody!
By 4u2ges - 5 Years Ago
The reason you cannot achieve what you want is, that the label is part of the bottle mesh. If you use opacity map, it does hide the bottle mesh. It you remove opacity map, iClone cannot handle PNG transparency.

There is a way though:

Apply a color diffuse map to the bottle material and a black map to its opacity channel. Set opacity slider to 100.
Apply your png texture to the label material and remove it.
Save generated opacity map.
Edit your png texture and apply background color same as bottle diffuse map.
Apply edited texture to label material. and replace opacity map with the one you've previously saved.
Make sure the roughness and metallic maps for label and bottle materials are in sync.
For both bottle and label decrease the opacity map strength to the desired level (must be the same for both).

https://forum.reallusion.com/uploads/images/08ed1890-ab77-47a1-be77-0c14.jpg

... or take it to Blender and separate labels mesh ;)

PS: Thanks for the bottle thebiz :)
By esemgee - 5 Years Ago
@4u2ges. Thanks. I presumed the label was part of the bottle, or something, so for me it was an error, or misjudgement, by the creators. Who wants to do all that unnecessary work when you should be able to just simply change the image, no metallic and roughness and so on! The bottle I used was $1 and is quite close to the proper bottle, so I am happy.