Jump to content
You must now use your email address to sign in [click for more info] ×

Affinity Photo: saving clipping path into JPEG


Recommended Posts

  • Staff

@NotMyFault
The post you quoted above is indeed correct and describes how to create a shape in Affinity that will be exported as a clipping path (generally speaking) within the JPG to be used in other apps (namely Photoshop). This path/shape must be nested in masking position as explained above.

The process you described is wrong and will not include any clipping path in the exported JPG file - it will simply export the clipped/visible portion of the image as raster data.

Link to comment
Share on other sites

4 hours ago, MEB said:

@NotMyFault
The post you quoted above is indeed correct and describes how to create a shape in Affinity that will be exported as a clipping path (generally speaking) within the JPG to be used in other apps (namely Photoshop). This path/shape must be nested in masking position as explained above.

The process you described is wrong and will not include any clipping path in the exported JPG file - it will simply export the clipped/visible portion of the image as raster data.

Interesting observation: i tried both methods on iPad and iMac M1, none worked. Both lead to white ("matted") background.

 I’m sure based on own memory that my way worked in older versions 1.9.

It seems Affinity Photo lost its ability to export JPG files with clipping path.

I tried all possible combinations of:

Area

  • Whole Document
  • Selection Area
  • Selection Only

Don't export layers hidden by Export Persona

  • active
  • inactive

Convert clips to paths (in "more ...")

  • active
  • inactive

 

Edited by NotMyFault

Mac mini M1 A2348 | Windows 10 - AMD Ryzen 9 5900x - 32 GB RAM - Nvidia GTX 1080

LG34WK950U-W, calibrated to DCI-P3 with LG Calibration Studio / Spider 5

iPad Air Gen 5 (2022) A2589

Special interest into procedural texture filter, edit alpha channel, RGB/16 and RGB/32 color formats, stacking, finding root causes for misbehaving files, finding creative solutions for unsolvable tasks, finding bugs in Apps.

 

Link to comment
Share on other sites

  • Staff

I don't know what you are doing exactly but whatever it is, it's not right. Have you enabled the option to convert clips to paths?
"Your" way never worked in any version because it was never implemented like that.
You may be confusing with exporting to PSD which does keep the path as a shape layer in Photoshop, but that's not the same as saving the shape as a clipping path in a JPG.

Link to comment
Share on other sites

13 hours ago, MEB said:

I don't know what you are doing exactly but whatever it is, it's not right. Have you enabled the option to convert clips to paths?
"Your" way never worked in any version because it was never implemented like that.
You may be confusing with exporting to PSD which does keep the path as a shape layer in Photoshop, but that's not the same as saving the path as a clipping path in a JPG.

 

Please try it yourself.

13 hours ago, MEB said:

Have you enabled the option to convert clips to paths?

Yes. (On desktop).
Edit: Just found this option is actually not available on iPad which explains my observation.

Mac mini M1 A2348 | Windows 10 - AMD Ryzen 9 5900x - 32 GB RAM - Nvidia GTX 1080

LG34WK950U-W, calibrated to DCI-P3 with LG Calibration Studio / Spider 5

iPad Air Gen 5 (2022) A2589

Special interest into procedural texture filter, edit alpha channel, RGB/16 and RGB/32 color formats, stacking, finding root causes for misbehaving files, finding creative solutions for unsolvable tasks, finding bugs in Apps.

 

Link to comment
Share on other sites

13 hours ago, MEB said:

You may be confusing with exporting to PSD

No. I tested explicitly export to jpg. Nothing else. 
Edit: i used the export preview, and didnt do the export in all cases. This lead to wrong conclusions on my side.

Mac mini M1 A2348 | Windows 10 - AMD Ryzen 9 5900x - 32 GB RAM - Nvidia GTX 1080

LG34WK950U-W, calibrated to DCI-P3 with LG Calibration Studio / Spider 5

iPad Air Gen 5 (2022) A2589

Special interest into procedural texture filter, edit alpha channel, RGB/16 and RGB/32 color formats, stacking, finding root causes for misbehaving files, finding creative solutions for unsolvable tasks, finding bugs in Apps.

 

Link to comment
Share on other sites

Would you mind sharing your exact settings? I will screen record my tests, but want to ensure that i don't miss something before starting.

Mac mini M1 A2348 | Windows 10 - AMD Ryzen 9 5900x - 32 GB RAM - Nvidia GTX 1080

LG34WK950U-W, calibrated to DCI-P3 with LG Calibration Studio / Spider 5

iPad Air Gen 5 (2022) A2589

Special interest into procedural texture filter, edit alpha channel, RGB/16 and RGB/32 color formats, stacking, finding root causes for misbehaving files, finding creative solutions for unsolvable tasks, finding bugs in Apps.

 

Link to comment
Share on other sites

3 minutes ago, NotMyFault said:

Please try it yourself.

I would be happy to test this for myself if I had a suitable file that had a clipping path in it, but I do not know how to create one that does. So if you could attach such a file to a post here I will try doing that.

All 3 1.10.8, & all 3 V2.4.1 Mac apps; 2020 iMac 27"; 3.8GHz i7, Radeon Pro 5700, 32GB RAM; macOS 10.15.7
Affinity Photo 
1.10.8; Affinity Designer 1.108; & all 3 V2 apps for iPad; 6th Generation iPad 32 GB; Apple Pencil; iPadOS 15.7

Link to comment
Share on other sites

Just  use pen  tool, create any closed curve.

Mac mini M1 A2348 | Windows 10 - AMD Ryzen 9 5900x - 32 GB RAM - Nvidia GTX 1080

LG34WK950U-W, calibrated to DCI-P3 with LG Calibration Studio / Spider 5

iPad Air Gen 5 (2022) A2589

Special interest into procedural texture filter, edit alpha channel, RGB/16 and RGB/32 color formats, stacking, finding root causes for misbehaving files, finding creative solutions for unsolvable tasks, finding bugs in Apps.

 

Link to comment
Share on other sites

  • Staff
25 minutes ago, NotMyFault said:

Would you mind sharing your exact settings? I will screen record my tests, but want to ensure that i don't miss something before starting.

I already did. The exact steps are in the post you are contesting saying it doesn't work like that (right on top of this same page).

Link to comment
Share on other sites

6 minutes ago, NotMyFault said:

Just  use pen  tool, create any closed curve.

And then what? IOW, how do I make it a clipping path? Does it matter what kind of file I start with, like a JPEG image or a multilayer Affinity native format file?

I do not mind testing but I do not want to waste time trying to make sure I am starting with whatever you are. That's why I asked for a sample file.

All 3 1.10.8, & all 3 V2.4.1 Mac apps; 2020 iMac 27"; 3.8GHz i7, Radeon Pro 5700, 32GB RAM; macOS 10.15.7
Affinity Photo 
1.10.8; Affinity Designer 1.108; & all 3 V2 apps for iPad; 6th Generation iPad 32 GB; Apple Pencil; iPadOS 15.7

Link to comment
Share on other sites

8 minutes ago, MEB said:

@JimmyJack,
Have you checked the Paths panel in Photoshop? The path should be there. You can use it however you want in Photoshop.

Ah, there she blows!
... was expecting it to come in already activated. Should've checked.

Edit: And again it works just for the masked version.

Link to comment
Share on other sites

ok, after rebooting my iMac and trying again:

 

The Export preview was misleading me.

Its always shows "matting" of the export, even if clipping gets applied and using transparency.

 

Screenshot 2022-05-05 at 18.23.55.png

Mac mini M1 A2348 | Windows 10 - AMD Ryzen 9 5900x - 32 GB RAM - Nvidia GTX 1080

LG34WK950U-W, calibrated to DCI-P3 with LG Calibration Studio / Spider 5

iPad Air Gen 5 (2022) A2589

Special interest into procedural texture filter, edit alpha channel, RGB/16 and RGB/32 color formats, stacking, finding root causes for misbehaving files, finding creative solutions for unsolvable tasks, finding bugs in Apps.

 

Link to comment
Share on other sites

2 hours ago, MEB said:

The issues with the export preview are known. On macOS it doesn't show the clipping at all - displays the whole image but that's unrelated with clipping paths.

giving up here. You are probably right. Even if I'm sure that the other way worked in older version (then on Windows), it doesn't make any sense to investigate into arcane history any further. Cannot rule out that the err is on my side. Too much effort to download old version, and export multiple variants (as preview is buggy).

 

There is more important things to do - sun is shining and my balcony emits more gravity than iMac and Affinity forum.

 

Mac mini M1 A2348 | Windows 10 - AMD Ryzen 9 5900x - 32 GB RAM - Nvidia GTX 1080

LG34WK950U-W, calibrated to DCI-P3 with LG Calibration Studio / Spider 5

iPad Air Gen 5 (2022) A2589

Special interest into procedural texture filter, edit alpha channel, RGB/16 and RGB/32 color formats, stacking, finding root causes for misbehaving files, finding creative solutions for unsolvable tasks, finding bugs in Apps.

 

Link to comment
Share on other sites

  • 1 month later...
On 5/5/2022 at 7:39 PM, NotMyFault said:

Cannot rule out that the err is on my side.

You might have had "too much" going on in your document. It appears that no proper field test was ever performed when the feature was implemented as it breaks if anything extra (even if hidden) exists in the document. But if you have the laboratory conditions where the feature was initially developed, it seems to work just fine ;-)

 

 

Link to comment
Share on other sites

  • Staff
On 6/12/2022 at 1:03 PM, lacerto said:

You might have had "too much" going on in your document. It appears that no proper field test was ever performed when the feature was implemented as it breaks if anything extra (even if hidden) exists in the document. But if you have the laboratory conditions where the feature was initially developed, it seems to work just fine ;-)

This happens if you place objects below the background layer with the nested masks (most likely due to the flattening on output). Objects placed above do not break the file - the layers are merged together but the paths are kept intact. In any case for their main purpose (hide backgrounds, have paths available to generate selections, for sell on stock sites) this is a moot point since the JPG format itself do not support layers, they are flattened on export and compressed. You are better served using app's native formats for complex documents.

The "laboratory" conditions are what they are because JPG's do not support clipping paths natively. It's an hackish way to improve the functionality of the format as Adobe has done with various other formats to increase its usefulness/meet certain needs. You also have to go through some quicks/requirements to save a JPG with clipping paths properly in Photoshop.

Link to comment
Share on other sites

44 minutes ago, MEB said:

The "laboratory" conditions are what they are because JPG's do not support clipping paths natively.

Yes, but I was using a native .aphoto document to produce a jpg file, so I would expect that objects that are hidden will be ignored when doing the export (as they are when making regular exports of the whole document, with or without a mask without producing paths). It seems that the reason why @NotMyFault failed to produce paths within a .jpg export was that they, too, when running tests, had multiple objects in the document for testing purposes, and had them hidden, below the object to be masked.

The export also fails when trying to limit the export to selected objects only (the paths are exported but the masked image is distorted because it is squeezed into the bounding box determined by the mask).

I can understand why these things happen but I made the post to show that there are pretty strict prerequisites to make the export successful. So if the implementation is not improved, the documentation could be more accurate.

Link to comment
Share on other sites

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.