aft Posted December 2, 2017 Posted December 2, 2017 The scenario is this: I have a folder with full-size landscape and portrait images I want to resize to max of, say, 800 width or 800 height for portrait). In addition, after the resize, I'll want to run additional sharpening. I've usually done this with a batch script in PS but the batch capability in affinity appears to preserve both dimensions recorded instead of applying only the value I changed. For example, I record a macro: change x dim=800 (affinity changes y dim to 640), sharpen. When I apply the macro to an image with slightly different proportions, it resizes it to the same 800x640 instead of fixing 800 and recalculating 640 for the new image proportion. I guess what I'm really looking for is resize using constraints. An 800x800 constraint would limit the long side to 800 and recompute the shorter side accordingly. Quote
carl123 Posted December 4, 2017 Posted December 4, 2017 You can try using the Filters > Distort > Equations filter to make the width (of any document) reduced to 800px and the height to scale proportionately. (use the settings as shown in the picture below) After this do a Document > Clip Canvas to get rid of the transparent background Both of these functions are recordable in a Macro so you can use them in a Batch process. Note: Images with an even number of pixels for the width (e.g. 2500px) seem to rescale correctly to 800px, images with an odd number of pixels in the width (e.g. 2501px) seem to rescale to 801px - presumably as you cant have fractions of a pixel Also sometimes a 1px transparent border is evident on one or more sides of the resized picture, but you can automatically Inpaint this out in the same Macro (let me know if you need further help with this) Quote To save time I am currently using an automated AI to reply to some posts on this forum. If any of "my" posts are wrong or appear to be total b*ll*cks they are the ones generated by the AI. If correct they were probably mine. I apologise for any mistakes made by my AI - I'm sure it will improve with time.
aft Posted December 5, 2017 Author Posted December 5, 2017 Thanks. I will give your way a go but it looks like it won't handle a mixture of landscape and portrait in one batch. I found an alternative which is to: 1. Use the batch screen and set the size constraints in the W,H fields. Affinity will limit the width or height to the longer dimension and adjust the other proportionally. Any pre-resize macros can also be executed at this time. Save to a non-lossy format. 2. Use the batch screen a second time applying the sharpen step (macro). Save to your format of choice. Quote
v_kyr Posted December 5, 2017 Posted December 5, 2017 Don't know if those sizing/transform/math-expressions will work in the batch fields too, but you may try and see if you can fine tune this further additionally with expressions as field inputs. Quote ☛ Affinity Designer 1.10.8 ◆ Affinity Photo 1.10.8 ◆ Affinity Publisher 1.10.8 ◆ OSX El Capitan ☛ Affinity V2.3 apps ◆ MacOS Sonoma 14.2 ◆ iPad OS 17.2
TravisL Posted April 24, 2024 Posted April 24, 2024 I know this is an old topic, but it would be great if the Document Resize would proportionally constrain so it could be used with the Batch Processor. Quote
walt.farrell Posted April 24, 2024 Posted April 24, 2024 7 hours ago, TravisL said: I know this is an old topic, but it would be great if the Document Resize would proportionally constrain so it could be used with the Batch Processor. I'm not sure I understand the scenario you're talking about. How would the Document Resize be used? And can't you simply do the resizing in the Batch Job? Quote -- Walt Designer, Photo, and Publisher V1 and V2 at latest retail and beta releases PC: Desktop: Windows 11 Pro 23H2, 64GB memory, AMD Ryzen 9 5900 12-Core @ 3.00 GHz, NVIDIA GeForce RTX 3090 Laptop: Windows 11 Pro 23H2, 32GB memory, Intel Core i7-10750H @ 2.60GHz, Intel UHD Graphics Comet Lake GT2 and NVIDIA GeForce RTX 3070 Laptop GPU. Laptop 2: Windows 11 Pro 24H2, 16GB memory, Snapdragon(R) X Elite - X1E80100 - Qualcomm(R) Oryon(TM) 12 Core CPU 4.01 GHz, Qualcomm(R) Adreno(TM) X1-85 GPU iPad: iPad Pro M1, 12.9": iPadOS 18.2.1, Apple Pencil 2, Magic Keyboard Mac: 2023 M2 MacBook Air 15", 16GB memory, macOS Sequoia 15.0.1
John Rostron Posted April 24, 2024 Posted April 24, 2024 @TravisL Try my macros to resize images to a fixed maximum size. These macros include one to resize to 800px. Note that the resizing algorithm is unspecified. Link here John Quote Windows 11, Affinity Photo 2.4.2 Designer 2.4.2 and Publisher 2.4.2 (mainly Photo). CPU: Intel Core i5 8500 @ 3.00GHz. RAM: 32.0GB DDR4 @ 1063MHz, Graphics: 2047MB NVIDIA GeForce GTX 1050
TravisL Posted April 25, 2024 Posted April 25, 2024 13 hours ago, walt.farrell said: I'm not sure I understand the scenario you're talking about. How would the Document Resize be used? And can't you simply do the resizing in the Batch Job? Here is a scenario where I found myself wanting a bit of extra functionality from Affinity. I have multiple images but I want to export it at multiple widths (e.g. 2400px, 1800px, 1200px) for a web design project. I have a whole folder of images with different size ratios that I need to export at multiple different resolutions with a particular setting in the JPEG output with specific matte and JPEG compression level. At the moment, these were the options available to me as far as I could see: Select all the images in the folder and use the Batch Job to export at one of these resolutions at a time (e.g. 2400px or 1800px), but manually selecting the JPEG settings each time since that doesn't save. Open each image individually and use the Export tab to set multiple output resolutions with the JPEG compression levels saved as an Export Setting. What would be ideal if there was a way to merge both these options, where I could set multiple output resolutions in the batch manager for the same output type at a time like in this screenshot OR the ability to apply the same export persona setting to multiple images simultaneously to process them in the Batch processor. One issue I've had when applying macros to resizing images using settings like Resize Document is that it will apply the new dimension (even the unspecified height dimension) to all images regardless of their size so images end up losing their width and height ratios and it doesn't work. 7 hours ago, John Rostron said: @TravisL Try my macros to resize images to a fixed maximum size. These macros include one to resize to 800px. Note that the resizing algorithm is unspecified. Link here John I'll have a look at this, thank you. John Rostron 1 Quote
walt.farrell Posted April 25, 2024 Posted April 25, 2024 9 hours ago, TravisL said: One issue I've had when applying macros to resizing images using settings like Resize Document is that it will apply the new dimension (even the unspecified height dimension) to all images regardless of their size so images end up losing their width and height ratios and it doesn't work. Thanks for the added details. That is probably due to the 1.7 bug that forces resampling, combined with the macro-processors by-design behavior that records the final height & width from the image you're using to record the macro. That means you have to use Filters > Distort > Equations to perform image resizing in a macro. John Rostron 1 Quote -- Walt Designer, Photo, and Publisher V1 and V2 at latest retail and beta releases PC: Desktop: Windows 11 Pro 23H2, 64GB memory, AMD Ryzen 9 5900 12-Core @ 3.00 GHz, NVIDIA GeForce RTX 3090 Laptop: Windows 11 Pro 23H2, 32GB memory, Intel Core i7-10750H @ 2.60GHz, Intel UHD Graphics Comet Lake GT2 and NVIDIA GeForce RTX 3070 Laptop GPU. Laptop 2: Windows 11 Pro 24H2, 16GB memory, Snapdragon(R) X Elite - X1E80100 - Qualcomm(R) Oryon(TM) 12 Core CPU 4.01 GHz, Qualcomm(R) Adreno(TM) X1-85 GPU iPad: iPad Pro M1, 12.9": iPadOS 18.2.1, Apple Pencil 2, Magic Keyboard Mac: 2023 M2 MacBook Air 15", 16GB memory, macOS Sequoia 15.0.1
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.