How to add an icon to a custom action?
Hi,
I am using the SDK to create a plugin which contains a custom action.
The action iteself it working perfectly however, I'm now trying to figure out how to add an icon to the menu, for this action.
I've come across this post but it isn't working for me: https://www.daz3d.com/forums/discussion/520721/embedding-pixmaps-in-plugin-and-setting-pane-icon
I don't get any errors but the icon never appears.
I've been trying to work out how the various Daz bridge plugins, such as DazToUnreal, are doing it.
They all seem to have a compiled cpp file for their icons at the top of which it says "Generated by DAZ PreCompiler from the following files".
Does anyone know what this "Daz PreCompiler" tool is?
Is it different to the standard QT rcc.exe?
It seems to output different data than rcc.exe so I'm guessing it's a different tool but I can't find any information about it online.
Any help would be most appreciated.
Thanks
Peter

Comments
Nevermind. I figured it out :)
Actually, I spoke too soon.
I found the DAZ PreCompiler and was able to compile my icon image the same way that the Bridges are doing it, but when I set the icon it still doesn't show up :(
That code looks roughly correct.
Does your call to
dpclook something like this?Are you linking the cpp file generated from dpc when you compile (ie is
images.cppin yourCMakeLists.txtsources)?Does
iconName = "action_icon"match the base filename of the image file you are passing to dpc?Thanks for the replies. I got it working.
In the end it seems my code was correct but what I needed to do was to remove the existing item from where I had assigned it to a menu in Daz Studio and re-add it for the icon to appear.