davidbjames Posted October 8, 2019 Share Posted October 8, 2019 Is it possible in Affinity Designer to export a selection (File > Export > PNG > Area: Selection without background) where there is masked content, with the resulting file being trimmed to only include the visible content. For example, I am creating a logo that has a background that extends well beyond the edges of the logo, where the logo shape reveals (via mask) the background I want visible. In fact, if I select the item in Designer the blue bounding box shows the rectangle of the visible content only. This is what I want to export. However, instead the export includes the entire area that the background occupies, so I then have to reopen the file in Preview to trim it down, which is obviously not very efficient. (btw, if I choose "Selection with Background" it then exports the entire file which I don't want. I just want the selection) Thank you, David Quote Link to comment Share on other sites More sharing options...
Staff Callum Posted October 8, 2019 Staff Share Posted October 8, 2019 Hi Davidbjames, I'm not sure if I understand your issue completely if possible could you provide the file in question a long with a screen recording demonstrating the issue? This will allow me to look into this further. Thanks C Quote Please tag me using @ in your reply so I can be sure to respond ASAP. Link to comment Share on other sites More sharing options...
davidbjames Posted October 8, 2019 Author Share Posted October 8, 2019 Here is a screenshot of the Export dialog, with the setting I want "Selection without background": https://cl.ly/50508bbd8932 I have attached a test document and exported document showing the problem. As you will note when opening the Designer document, the background of "FOO" are large rectangles that extend beyond the "FOO" mask. If you select the main layer you will note that the selection does not include the background, but only the masked area. However, if you export this (the Test Foo.png file) you will see that the resulting PNG includes the entire area, so requires trimming later. (I think all this was clear in my post, but now you have some examples to work with.) Test Foo.afdesign Quote Link to comment Share on other sites More sharing options...
dutchshader Posted October 8, 2019 Share Posted October 8, 2019 you can create the same without the use of masks. example attached. Test Foo2.afdesign Quote intel core i5, 16GB 128Gb ssd win10 Pro Huion new 1060plus. philips 272p 2560x1440px on intel HD2500 onboard graphics Razer Tartarus Chroma Link to comment Share on other sites More sharing options...
davidbjames Posted October 8, 2019 Author Share Posted October 8, 2019 That's pretty cool @dutchshader How did you do that? Also is it possible to select the shape afterword to resize? Quote Link to comment Share on other sites More sharing options...
dutchshader Posted October 8, 2019 Share Posted October 8, 2019 For the foo text i used a boolaen add. The rectangles i pasted inside foo ctrl>alt>V and yes you can resize afterwards. Quote intel core i5, 16GB 128Gb ssd win10 Pro Huion new 1060plus. philips 272p 2560x1440px on intel HD2500 onboard graphics Razer Tartarus Chroma Link to comment Share on other sites More sharing options...
davidbjames Posted October 8, 2019 Author Share Posted October 8, 2019 Thank you. I love boolean operations! In any case, this is not a solution to my problem because I need to use masks (e.g. the background is much more complex than the rectangles I made in the example). Quote Link to comment Share on other sites More sharing options...
dutchshader Posted October 8, 2019 Share Posted October 8, 2019 on text you don't even need the boolean operations. 20191008_154501.mp4 Quote intel core i5, 16GB 128Gb ssd win10 Pro Huion new 1060plus. philips 272p 2560x1440px on intel HD2500 onboard graphics Razer Tartarus Chroma Link to comment Share on other sites More sharing options...
davidbjames Posted October 15, 2019 Author Share Posted October 15, 2019 Thanks so much @dutchshader for the excellent video demonstration! (learned this today!) However getting back to my original question, should I report this as a bug? 1. Create a background on a layer that extends across the screen 2. Create an object or text on the same layer (the size should be smaller than the background to see the problem) 3. Make the object into a mask for the layer so only the background shows for that area 4. Select the layer 5. (note that blue bounding box shows only the area of the mask, not the entire background) 6. Export > PNG > Area > Selection without background... Save. Expected result: PNG size to include only the selection/masked area. Actual result: PNG size includes the entire area of the background. Quote Link to comment Share on other sites More sharing options...
davidbjames Posted December 20, 2019 Author Share Posted December 20, 2019 Affinity staff, I would be grateful if you could take my last post as a bug report. This is still occurring for me. Thank you. Quote Link to comment Share on other sites More sharing options...
niksac Posted June 15, 2020 Share Posted June 15, 2020 Having the same issue here Quote Link to comment Share on other sites More sharing options...
davidbjames Posted October 20, 2020 Author Share Posted October 20, 2020 This is an old issue, but I was able to isolate the problem further. If you make the selection by clicking on the layer palette, presuming this would just be a regular selection of that layer/sublayers, then the problem is reproduced. The exported image is sized with excess background around the intended selection. However, if you "drag select" the same area, then there is no problem. The exported image is sized correctly. Quote Link to comment Share on other sites More sharing options...
Darner Posted April 3, 2021 Share Posted April 3, 2021 Having the same problem. - Paint within a mask - Export PNG without background - Content outside masked area is also visible in the transparent PNG. Hope you can fix. Thank you!! Quote Link to comment Share on other sites More sharing options...
JamesH Posted June 30, 2022 Share Posted June 30, 2022 Same issue here. I have a logo that has elements masked and it adds invisible pixels outside of the edge of the logo export which are not desired. Why isn't there an export selection that is visible option? Slices are also not ideal as they are fixed in a grid when scaling and I can't get it to properly position around my graphics. Very annoying. Quote Link to comment Share on other sites More sharing options...
Old Bruce Posted July 1, 2022 Share Posted July 1, 2022 16 hours ago, JamesH said: Slices are also not ideal as they are fixed in a grid when scaling and I can't get it to properly position around my graphics. Very annoying. You should try using the Layer to Slice feature of the Export Persona. Quote Mac Pro (Late 2013) Mac OS 12.7.4 Affinity Designer 2.4.1 | Affinity Photo 2.4.1 | Affinity Publisher 2.4.1 | Beta versions as they appear. I have never mastered color management, period, so I cannot help with that. Link to comment Share on other sites More sharing options...
JamesH Posted July 4, 2022 Share Posted July 4, 2022 On 7/1/2022 at 10:49 AM, Old Bruce said: You should try using the Layer to Slice feature of the Export Persona. It doesn't seem to work for me. See the square borders are showing elements beyond the visible edge. Quote Link to comment Share on other sites More sharing options...
JamesH Posted July 4, 2022 Share Posted July 4, 2022 I figured it out. Its very finicky. If the node is just pasted the halfway point of the border edge, it adds pixels. I just had to move this node to the left. Solved. Old Bruce 1 Quote Link to comment Share on other sites More sharing options...
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.