PeterT Posted April 4, 2017 Share Posted April 4, 2017 On another note, when pasting in a 26x20 pixel tool Icon in the Edit Definition Properties tab, how do you get a high resolution Icon. I made my Icon in Graphic Converter, but when I pasted it in, I got some sort of a message saying that it would be a low resolution Icon if I do not make a high-resolution counterpart, or something like that. What is the technique to get a high resolution tool Icon? Quote Link to comment
JBenghiat Posted April 5, 2017 Share Posted April 5, 2017 Save a copy of the image at double the resolution and append "@2x" to the image file name. VW will search for the second image in the same directory. Hth, Josh Quote Link to comment
PeterT Posted April 5, 2017 Author Share Posted April 5, 2017 Josh, As you Paste the image into the Properties dialog, what directory do I put the High res image into? Where does Vectorworks store the image that was pasted in? Is that where I need to put the high res image? Thanks, Peter Quote Link to comment
JBenghiat Posted April 5, 2017 Share Posted April 5, 2017 Hi Peter, The regular and high resolution images just need to be in the same folder before you import. Select the regular image with the Import PNG Icon..: dialog, and VW will automatically pull in the high res as well. No need to find where VW stores the image. -Josh 1 Quote Link to comment
PeterT Posted April 6, 2017 Author Share Posted April 6, 2017 (edited) Josh, Since Vectorworks and the Plug-ins reside on seven different workstations in my office, are you suggesting I put two image files on each of seven workstations? Or can a workstation copy of Vectorworks pull the icons from our server? I typically Paste the icon in on my workstation, how will the other workstations find it? Is there anything about this on the Developer Page? I have not seen it. Peter Edited April 6, 2017 by PeterT Quote Link to comment
JBenghiat Posted April 6, 2017 Share Posted April 6, 2017 Hi Peter, It's much simpler than you are describing. The icon gets embedded into the plug-in, so after you select the icon with the [Import PNG Icon...] button, you're done. You could even delete the original icons from your workstation if you would like, but the embed process means you can't retrieve an icon from a plug-in. Example workflow: - Create an icon at double resolution. - Save as MyIcon@2x.png - Using your image editor, reduce the resolution in half - Save as MyIcon.png in the same folder as MyIcon@2x.png - In VW Plug-In Manager -> Edit Definition -> Properties, press [Import PNG Icon...] - Select MyIcon.png At this point both MyIcon.png and MyIcon@2x.png embed in the plug-in. As a side note, SDK based plug-ins deal with the icon differently, so don't be confused by any information you may find about adding icons to .vwr files. HTH, Josh Quote Link to comment
PeterT Posted April 7, 2017 Author Share Posted April 7, 2017 (edited) O.K, I am about to give up on this. I have a 26x20 pixel PNG Icon named BLIcon.png, and a 52x40 pixel PNG icon named BLIcon@2x.png. I Open the BLIcon.png file in Preview, Photoshop, or Graphic Converter and they all tell me it is a 26x20 PNG file. In VectorScript I hit the Import PNG Icon... button, select the BLIcon.png file, and get the message that "The PNG file is the wrong size. The dimensions must be 26x20 pixels". I have verified 20 times that it is a 26x20 PNG file yet VectorScript sees it as something else. I cannot spend my whole day trying to import a stupid ICON. I guess I will just have two accept the low res icon since VS will not take the file that it asks for. Here are the two Icons, as I do not know where to go from here. Edited April 7, 2017 by PeterT Quote Link to comment
MullinRJ Posted April 7, 2017 Share Posted April 7, 2017 Peter, I just copied the two images you posted and saved them from Preview to my desktop, naming them appropriately as A.png and A@2x.png. They imported as I expected and invoked no error message. I saved them twice, with and without the alpha channel, but VW imported both versions the same. I am not sure where your problem lies, but I don't think it is with the image files. Raymond Quote Link to comment
PeterT Posted April 7, 2017 Author Share Posted April 7, 2017 Raymond, I do not know how you got them to import. I get the same message every time. I even renamed them the same as you did. Peter Quote Link to comment
JBenghiat Posted April 7, 2017 Share Posted April 7, 2017 I think my last reply didn't go through. Check that both images are at 72 dpi. I found that even if the pixel dimensions are correct, if they are not set for screen resolution, VW will produce an error. Also just confirm that your @2x version is 52 x 40 @ 72 dpi. -Josh Quote Link to comment
PeterT Posted April 7, 2017 Author Share Posted April 7, 2017 OK, I had them both at 600 dpi. I do not understand how you can have a high resolution image at 72 dpi and only 26 x 2o pixels. I will reduce them to 72, but that does not sound high resolution to me. Peter Quote Link to comment
JBenghiat Posted April 7, 2017 Share Posted April 7, 2017 High resolution specifically refers to displays, like Apple's retina displays, that have twice as many pixels per inch. Because the icon size is the same display size on both kinds of screens, 52 x 40 is twice the resolution of 26 x 20, and in comparison, high resolution (or at least 2x resolution). In theory, keeping the image the same measured dimensions, say in mm, but changing the dpi from 72 to 144 should work, but even though the pixel dimensions are incorrect, VW is finicky about it. Personally, I think VW should just look at the pixel dimensions and not the dpi, but that doesn't look like it will change any time soon. The @2x concept is actually a graphics standard and not unique to VW: https://developers.google.com/web/fundamentals/design-and-ui/media/images#relative-sized-images -Josh Quote Link to comment
J. Miller Posted May 15, 2018 Share Posted May 15, 2018 72 DPI resolution killed me too. If only it was mentioned in the dialog that says to use a 26 x 20 pixel image Thanks Josh Quote Link to comment
DCarpenter Posted April 11 Share Posted April 11 I lost a couple hours on this issue as well. This thread saved me from pulling the rest of my hair out. Sure would be nice is VW could add that little note to the dialog box that pops up that the image also needs to be 72 dpi. Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.