Jump to content

Recommended Posts

Hey I want to flag this bug/issue again since it is still not being address or fixed and is creating a workflow in affinity that I can no longer continue to use. Please see video below of the example of how force pixel alignment does not work.

It is becoming a serious headache, namly the export persona constantly exporting images with a 1px gap. I have since, through shear perservance learned the work flow to get around this problem. Forced pixel alignment should do what it says and the whole document works precisely on whole pixels regardless of scale, snapping or repositioning. Perhaps affinity should even add this as a clear option when creating a document in the first place. Add a tick box option next to the 'document units' dropdown menu and call it 'work with whole pixels'. Then have the additonal forced pixel button in the toolbar.

My problem I face now is when a scale an object, let's say a simple piece of text. It does not scale to whole pixels. It introduces the fractured pixels, even though the whole documnent is working in forced pixel alignment. Due to this I have to constantly monitor and be aware of resizing everything to make sure it is working in full pixels. Is there a way when I scale an object, ie grabbing the blue handle points and increasing or decreasing its size, while maintaining full pixels? This would help massively on my end in solving how affinity works.

Like others though this is really beginning to dent my ability to use Designer going forward. It is literally adding hours to my work flow.

https://www.loom.com/share/d4d68bbd50ac4a68892ca40852a5cf72

Share this post


Link to post
Share on other sites

 

It would be good to have a preference tick to force absolutely everything to scale (seems happens more when shift scaling) with no partial pixels.

A dirty work around idea. Setting in preferences / user Interface / Decimal Places for Unit Types and setting there "0" for pixels doesn't do it, I guess? . I made a test, and does not do decimal pixels, but of course, when it is in doubt will add or remove one pixel. But I tested generating artistic text, and a text box, too, and both produce no partial pixels, obviously. This has bad implications for accuracy, as vectors are infinitely more precise, but for your very use case, that you need all pixel-exact, maybe this could be a workaround, provided taking care of some things...

no-decimals.jpg.d8369c5bc4a6758e5f917b5807018e62.jpg

Another idea is, having in a side kind of boxes as refs, and activating all the snaps, so that you can resize to snap all text boxes over a sample box, so to make them all same size (than that one) and so ensuring pixel-perfect, no partial pixels. So, you might need several box samples (several sizes or proportions) as a "pallete", then scale the item over whatever the sample box to snap to those boxes (which are of course pixel perfect).

For the workarounds, the snapping options might become handy (to activate or deactivate)

snapping_settings.thumb.jpg.204deb9559594504d0ac3ee08fcb126a.jpg

 

I dunno. That's how I'd attack that (surely with the first idea). Sorry if you knew all this.


Affinity Designer and Affinity Photo licenses, Windows 7, i7  860 (2009) 2.8 GHz,  8 GB RAM, GTX 1050 2 GB, HD 7200 RPM.  Wacom Intuos 4 XL.

Share this post


Link to post
Share on other sites

@SrPx thanks for the response buddy. Setting the decimal place to zero unfortunately achieves nothing. In essence all it is doing is hiding the decimal places so you can’t see them. But under the hood it is still introducing fractured pixels. So ultimately the pixel persona will still export slices with a 1px gap. This is the biggest grip for me because it is so freaking obvious when uploading these slices to client websites.

Your other solution is a nice idea (thanks for that) but again it far more work than it should be. I don’t want to have to consciously be aware that my various layers are being contained in boxes. It completely defeats the simplisticty that affinity is suppose to be boasting. Until affinity decide to fix this I can’t see a walk around. As this has been a problem since launch (2014) and they have done nothing about it, does sadden me. I was / am a huge fan of affinity. But the work flow to export all my slices, symbols, images etc from my designs is simply making this a product I can’t use anymore. For messing around and chilling it’s fantastic. But for real client work uploading all your artwork with a white 1px gap is tragic. It even did it for a professional brochure I made (26 pages) with hundreds of layers. You can imagine my frustration when I had to refactor every single layer making sure both the physical size of the layer was solid pixels only, but also the position on the art board being solid pixels. If any one of those 4 measurements has a fractured pixel then it will upload the entire slice with a 1px gap. It is actually a really shocking  error/bug and I can’t believe this hasn’t been given more light.

thanks for the input

Share this post


Link to post
Share on other sites
11 hours ago, davidlower8 said:

Forced pixel alignment should do what it says

Forced pixel alignment generally does do what it says, but (counterintuitively, as far as I’m concerned) ‘Move by whole pixels’ takes precedence.


Alfred online2long.gif
Affinity Designer/Photo/Publisher 1.7.2.471 • Windows 10 Home (4th gen Core i3 CPU)
Affinity Photo for iPad 1.7.2.153 • Designer for iPad 1.7.2.6 • iOS 12.4.1 (iPad Air 2)

Share this post


Link to post
Share on other sites

If you have "Move by whole pixels" turned on - it will do exactly that - move things by whole pixels. If your object is off pixel at the start, it will remain off pixel at the end (the new position will keep the relative pixel-local offset).  Try turning it off.  You might find it's all magically 'fixed' a lot of your issues.

 

Arguably "Force pixel alignment" is not the best choice of words.  Essentially, it is just snap to pixel position - but it will only snap to a pixel boundary if there is no other real snap that is taking place for each axis.

 

As far as scaling goes - if you do a constrained scale, then you have the potential to put one of your edges off pixel.  This is because we keep strict proportions, and the overall scale change will not result in a new size that is whole pixels in both axes.  If we didn't keep strict proportions, you could end up with transforms that tend towards shapes at 1:1.  Not a problem for large objects, but if you are working on icons at 32x32 pixels, you can quickly lose the aspect ratio of your objects if you scaled and both axes conform to a pixel position.

This is also true if you snap alignment to another object or guide which is off-pixel.

 

@SrPx The precision setting is only to set how many decimal places are shown in UI - it does NOT affect the internal precision of the actual values.


SerifLabs team - Affinity Developer
  • Software engineer  -  Photographer  -  Guitarist  -  Philosopher
  • iMac 27" Retina 5K (Late 2015), 4.0GHz i7, AMD Radeon R9 M395
  • MacBook (Early 2015), 1.3GHz Core M, Intel HD 5300
  • iPad Pro 10.5", 256GB

Share this post


Link to post
Share on other sites
Quote

The precision setting is only to set how many decimal places are shown in UI - it does NOT affect the internal precision of the actual values.

I kind of was suspecting that even at the time of writing it (that it was not really averaging  or rounding the position)... Anyway, it does not affect my workflow (as I don't have the specific use/need that davidlower8 has). I am not sure about what would be the best path for davidlower8's work.


Affinity Designer and Affinity Photo licenses, Windows 7, i7  860 (2009) 2.8 GHz,  8 GB RAM, GTX 1050 2 GB, HD 7200 RPM.  Wacom Intuos 4 XL.

Share this post


Link to post
Share on other sites

Point is that there should be the way to make no gap between attached objects by snapping.
Adobe Illustrator doesn't create gap if objects are attached by snapping.
Illustrator does anti alias so that's not gonna be an excuse.

Share this post


Link to post
Share on other sites

@ashf Not sure exactly what you mean?  If you use snapping, objects will snap to each other with no gap (the issue of antialiased lines between edges is another issue).  The issue in this thread is to do with the behaviour related to snapping to pixel positions - a completely separate issue to snapping to other objects in your document.

 


SerifLabs team - Affinity Developer
  • Software engineer  -  Photographer  -  Guitarist  -  Philosopher
  • iMac 27" Retina 5K (Late 2015), 4.0GHz i7, AMD Radeon R9 M395
  • MacBook (Early 2015), 1.3GHz Core M, Intel HD 5300
  • iPad Pro 10.5", 256GB

Share this post


Link to post
Share on other sites
8 hours ago, Ben said:

@ashf Not sure exactly what you mean?  If you use snapping, objects will snap to each other with no gap (the issue of antialiased lines between edges is another issue).  The issue in this thread is to do with the behaviour related to snapping to pixel positions - a completely separate issue to snapping to other objects in your document.

 

As OP emphasized "export persona constantly exporting images with a 1px gap", I believe antialiased 1px line problem is the actual point on this topic.
 

Share this post


Link to post
Share on other sites
9 hours ago, Ben said:

@ashf Not sure exactly what you mean?  If you use snapping, objects will snap to each other with no gap (the issue of antialiased lines between edges is another issue).  The issue in this thread is to do with the behaviour related to snapping to pixel positions - a completely separate issue to snapping to other objects in your document.

 

I thought this is related to an antialias problem.

Share this post


Link to post
Share on other sites

I'm curious, David. before trying Affinity, did you do this type of Work in Illustrator, or in Sketch/Figma/etc. Did those solutions provided you with pixel perfect outputs while working with vectors? . I can't see a way of doing it if not by rounding the proportional scale (by not making it fully proportional scaling (which would be terrible by all means), or snapping to certain positions in some way, while scaling (so, disallowing certain scaling possibilities, by snap). Is solely mere curiosity, nothing more.


Affinity Designer and Affinity Photo licenses, Windows 7, i7  860 (2009) 2.8 GHz,  8 GB RAM, GTX 1050 2 GB, HD 7200 RPM.  Wacom Intuos 4 XL.

Share this post


Link to post
Share on other sites

@ashf Antialiasing is not the problem.  The problem you see is due to the slice rectangle being calculated from the bounds of an object which is not precisely on a pixel boundary.  The antialiasing is due to rendering that off-pixel object.

 


SerifLabs team - Affinity Developer
  • Software engineer  -  Photographer  -  Guitarist  -  Philosopher
  • iMac 27" Retina 5K (Late 2015), 4.0GHz i7, AMD Radeon R9 M395
  • MacBook (Early 2015), 1.3GHz Core M, Intel HD 5300
  • iPad Pro 10.5", 256GB

Share this post


Link to post
Share on other sites

@SrPx I think a lot of the issues come from people working mainly in Photoshop, which is natively a pixel-space workspace, but think they are using real vectors (when they are not).  Any scaling gets rounded to whole pixels when the transform is applied.

 

Affinity uses a full precision vector model.  The rounding happens at the end (for example, when finding slice bounds).  We don't want to round out precision early on, because that error gets compounded as you do subsequent transformations.


SerifLabs team - Affinity Developer
  • Software engineer  -  Photographer  -  Guitarist  -  Philosopher
  • iMac 27" Retina 5K (Late 2015), 4.0GHz i7, AMD Radeon R9 M395
  • MacBook (Early 2015), 1.3GHz Core M, Intel HD 5300
  • iPad Pro 10.5", 256GB

Share this post


Link to post
Share on other sites

Hey guys sorry for the delay in getting back to you all. @SrPx I only tried photoshop but limited amounts. I was not using it for the current workflow I am using affinity for.

I am thinking I may have named this thread  incorrectly. The real issue as @ashf pointed out is the 1px gap that export persona exports slices. If you export png with transparent backgrounds or none contrasting backgrounds you’re unlikely to see the problem. The issue is I can’t work in solid pixels. There is NO setting to do this. Forced pixel alignment and moving whole pixels is technically correct in their functionality. But it means every layer never works to whole pixels. As a result export persona always round up to nearest pixel. So there is always a gap between actually image and the slice dimensions the persona makes. So for me this means I can not work in solid pixels which really makes those other features somewhat pointless to have. I am wondering if there is a way to create whole pixel documents?

Share this post


Link to post
Share on other sites

@Ben I agree with your last assessment.

Export persona needs to export images without this gap. For me it really doesn’t matter if it’s full pixels, in fact I think it’s better to not have full pixels as you just pointed out. But when you make a black and white brochure and every single page has a thin white edge, it’s highly contrasting. So affinity should program the export persona to export precisely the layer or round up the layer to full pixels. Either way the current setup is clearly broken.

Share this post


Link to post
Share on other sites

@davidlower8 Here is our problem - that works for your workflow, but other people (historically) have used slices for pixel based export. So, the pixel alignment matters - a lot.  It also matters that our pixel preview mode shows what they will export.

 

Out of curiosity - why use slices for exporting a brochure?  Most people would use pages or artboards and export to PDF for this purpose?  Arguably, for print, you should also be using bleed anyway to get around the issue of colour changes at edges.


SerifLabs team - Affinity Developer
  • Software engineer  -  Photographer  -  Guitarist  -  Philosopher
  • iMac 27" Retina 5K (Late 2015), 4.0GHz i7, AMD Radeon R9 M395
  • MacBook (Early 2015), 1.3GHz Core M, Intel HD 5300
  • iPad Pro 10.5", 256GB

Share this post


Link to post
Share on other sites

A clear example of this issue can be found here. https://abigaillower.com. Scroll down to about section and click on brochure button (it’s a large file so be patient). On this brochure you can see throughout, multiple thin white lines surrounding the different pages at varying degrees. Some on the side, some on top and other slides none at all. This is all because export persona is rounding up to the nearest solid pixel for every page/slide and therefore introducing a gap. I haven’t fixed it yet because I simply have not got the time to go into every layer and correct everything to solid pixels. There’s over 200 hundred layers.

Share this post


Link to post
Share on other sites

@Ben this was a digital brochure, so print was not needed. Also this brochure was exported as a whole document as a pdf (did not use export persona). I do all my work on art boards. Regardless the issue remains. Doesn’t matter the export or way I work. The simple fact is if I export anything in affinity that is not whole pixels affinity will export to the nearest whole pixel. That for me is broken and introducing ‘stuff’ I don’t want.

 

Most of my work is making designs for websites and various other things. So I want to be able to export my assets simply with export persona for the various sizes and file types. It’s really great for that.

Share this post


Link to post
Share on other sites

ok - looking at your pdf, I'd say you do have a workflow issue.  If you we using artboards, with lapped objects, it'd take care of this.


SerifLabs team - Affinity Developer
  • Software engineer  -  Photographer  -  Guitarist  -  Philosopher
  • iMac 27" Retina 5K (Late 2015), 4.0GHz i7, AMD Radeon R9 M395
  • MacBook (Early 2015), 1.3GHz Core M, Intel HD 5300
  • iPad Pro 10.5", 256GB

Share this post


Link to post
Share on other sites
1 minute ago, davidlower8 said:

@Ben this was a digital brochure, so print was not needed. Also this brochure was exported as a whole document as a pdf (did not use export persona). I do all my work on art boards. Regardless the issue remains. Doesn’t matter the export or way I work. The simple fact is if I export anything in affinity that is not whole pixels affinity will export to the nearest whole pixel. That for me is broken and introducing ‘stuff’ I don’t want.

Then the issue has to do with your document, not Slices or pixel rounding.


SerifLabs team - Affinity Developer
  • Software engineer  -  Photographer  -  Guitarist  -  Philosopher
  • iMac 27" Retina 5K (Late 2015), 4.0GHz i7, AMD Radeon R9 M395
  • MacBook (Early 2015), 1.3GHz Core M, Intel HD 5300
  • iPad Pro 10.5", 256GB

Share this post


Link to post
Share on other sites

@Ben I exported the document as a whole pdf document from the main menu. Not with export persona or multiple slices. 

If it is a workflow issue I’d love to know how to fix it. But from my understanding having tried to fix this issue over multiple threads it is to do with affinity exporting to whole pixels when my designs are perhaps not. As I showed in the video at the very beginning.

Share this post


Link to post
Share on other sites

Hi @MEB ok so I have sent the file. I have also sent a more modern file with a workflow I use frequently with a better awareness of how Affinity works. Again the main issue is being able to work without worrying if a layer is in full pixels and then being able to upload the various assets/slices. I want to avoid the gap that export persona creates with slices. If it is a workflow issue then fantastic, hopefully you will be able to enlighten me. Please note I have already had a couple of these threads before with other moderators telling me what I should do. It does not work. I look forward to hearing from you. Thank you. The video in the beginning thread highlights the issue nicely. Cheers.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×