Jump to content

Recommended Posts

Posted

Hi from the "crazy French",

I need to slightly rotate an image (jpeg file) of text in order to have perfectly horizontal text lines. After rotation, there is a tilted band of "empty areas" all around the image, as shown in the picture below that illustrates the lower left corner of the full rotated image.

Capturedecran2024-02-08a11_24_352.png.ec510fbe9965409ca5ecb408c8704bb5.png Figure 1

I need to eliminate this empty band, and I use the following method. First I select a rectangular vertical zone of the image:

Capturedecran2024-02-08a11_25_35.png.7eb776cf64976cd12fdacc98f0b8eb00.png Figure 2

Then I stretch the selceted area towards left:

Capturedecran2024-02-08a11_26_28.png.3098a06cb403d3792ffaef57db47a152.png     Figure 3

Everything seems OK. However, if I look at the fontier beween the right "original (unstretched) area" and the left "stretched arae", I see:

Capturedecran2024-02-08a11_33_03.png.53f26e1bc9e5786ea92e8cbac9f2982d.png    Capturedecran2024-02-08a11_36_15.png.e1e5e5ce3bb1fcac790c7cf17209869c.png Figure 4

On the left image above the frontier is within the 2 vertical blue line. The right image shows an enlarged version (using cmd+) of the frontier where the left blue vertical line is still visible. About 3 dots right of this vertical blue line the frontier is seen as a "fuzzy" area about 2 dots thick.

NB: all my transformations are done using "Force pixel alignment" and "move by whole pixels"; all the iamges above are screenshots taken along the my work on the file.

I f i export (jpeg) my image/file and close the file, then reopon it later, the fuzzy area has been stored and is visible "forever"!  I don't want that uggly result.

Now, if I export (jpeg) and close my image/file just after rotation (Figure 1), then reopen this jpeg file, and proceed to stretching as in Figure 2 and 3, there is no fuzzy area at the frontier between the stretched and unstretched area. This is the behavior that I need and want!

My questions are:

  • Are these 2 different behaviors normal and, if yes, why?
  • Is it due to the difference between dots and pixels?
  • Or is it a bug?

PS: I am unable to remember woh is who among "pixel" and "dot"; maybe I interchanged the 2 words above!!!

 

 

Capture d’écran 2024-02-08 à 11.24.35 2.png

Posted
49 minutes ago, Lobivia said:

NB: all my transformations are done using "Force pixel alignment" and "move by whole pixels";

Generally you should have "Move by whole pixels" turned off. I don't know if that would matter in this case. And I don't have answers for your questions; sorry.

-- 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.5, Apple Pencil 2, Magic Keyboard 
Mac:  2023 M2 MacBook Air 15", 16GB memory, macOS Sequoia 15.5

Posted

Stretching a Pixel layer will cause the pixels to be 'stretched' and, like stretching a rubber band, the more you stretch it the ‘thinner’ the material will be, making it more transparent.

The more you stretch a pixel layer the more transparent the pixels will be as the ‘amount of pixel content’ has to cover a larger area.

This is normal behaviour for the Affinity applications, although I’ve heard that it is different in some other applications.

The effect of stretching will be exacerbated with a rotated raster layer as the pixels don’t ‘align with’ the pixel grid ‘properly’.

(The effect is less-noticeable in Photo because Photo always displays the document as ‘pixel-resolution’.)

One way to get round this is to duplicate the stretched layer to ‘multiply’ the stretched pixels.

Posted

Hi Garry

As usual, I learnt many things: I appreciated your expalanations and video. Your image of "dilution of « pixel content » by stretching on a rubber band" is excellent! The second part of the explanation about alignment of "effective" pixels and pixel grid is related to what "I felt": some conflict between the "quantified"(pixellated) image and the space where it is quantified; however some "hidden algorithm" is involved when alignment is "restored" or "forced" upon saving or closing the file; when the image is displayed on the screen at high magnification (my figure 4 right) something like "smoothing" is used… It seems obvious to me that this smoothing and the "restored/forced" alignment are not "commutative operators", otherwise my method based on closing and reopening the rotated file would not be successful…

I checked the method provided by the video, but the result is not satisfactory for my images. I guess that "behind" the edit>inpaint there is again "some algorithm" that "extrapolates the  pixels added to the trasnparent area by "Grow/Shrink", depending on the number of pixels added at this "Grow/Shrink" step. If it can work for fuzzy objects like cloud or grass, etc… it is not satifactory for the granular structure of the background paper in my pictures.

However, all what you told gives me further ideas to improve my method…
The most complex part of our discussion is that with Affinity Photo in French I have had to switch between the French and English versions of the software which implies restart! 😉

Posted

If the Inpainting Brush Tool isn’t giving you a decent result, one other option you have in this case would be the Patch Tool.

See attached video.

Rasterise the image, then roughly select the area you want to fill, then move the mouse pointer until you see the gap has been filled nicely, then click outside of the selection to make the patch, and click again to confirm.

Then ‘run-over’ the patch with the Inpainting Brush Tool and it should be good enough for most purposes.

Posted

Hi Garry,

Nice idea to chain the patch and inpainting tools… Moreovers, the "dirty yellow" image that is used in the video is similar to that I have to deal with.
I confess that I learn something new every day! There are so many tools that I ignore……… 🫣

Posted
3 minutes ago, Lobivia said:

There are so many tools that I ignore

I keep forgetting what’s available, which is why I have such a large Tools Panel with most of the tools ‘in my face’ and easy to see, even if I still forget what some of them are and what they can be used for.

Posted

What you write means that you made the video just for me!? Thanks x Thanks 😃
I have remarked the very many tools on the tool panel. I could not work with such a toolbox: I would be looking for the appriopriate tool forever as I do with my true tool box looking for the small screwdriver which is hidden among the hammer, the soldering iron, electric wires, etc…

Posted
6 hours ago, Lobivia said:

I have remarked the very many tools on the tool panel. I could not work with such a toolbox: I would be looking for the appriopriate tool forever...

Like in GarryP's screenshot the tools can separated into groups using the horizontal divider line (the last item in the Customize Tools flyout). This may help you with that, much like using different drawers in a mechanics style toolbox can help make finding the desired tool quicker & easier.

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

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.