Author Topic: Export PNG fro SVG without antialiasing 90 degrees edges  (Read 1450 times)

April 15, 2018, 04:43:21 AM
Read 1450 times

Zgred

  • Sr. Newbie

  • Offline
  • **

  • 3
Hi. Is there any way to disable antialiasing of straight (90 degrees) edges when exporting to png?
I have to prepare separate textures (in this example green and orange) with transparency for the 3d program, which will be seamlessly connected as in the picture below.
The problem is that the connections between them will be visible as a result of antialiasing, so I am looking for a solution.
Thx





  • 0,92

April 15, 2018, 06:19:34 AM
Reply #1

Lazur

  • IC Mentor

  • Offline
  • ******
  • Inkscape Filters Wizard

  • 1,154
  • Gender
    Male

    Male
Hi.

In the document's settings you can switch off anti-aliasing which may/may not work for you.
Recently made a template which filters the parent layer=everything on screen to be drawn with black or white, with no anti-aliasing available here.

Probably the latter as it is won't fit your needs but something similar can be made wich uses two colours instead the black.

Fact is the current workaround to avoid the gap issue is forcing the transparency values instead of an additive alpha channel blending mode. Made some bug reports about the latter, hope it got into the gurus discussion at lgm.
(Can be achieved in inkscape too but needs special preparation).
Therefore you can force aliasing best with no transparencies. Which may or may not work for you.

Other option is to use overlapping. Which may or may not work depending the export resolution. And other factors, how easy it is to implement it on each stroke.

Other option is to produce the image by clipping overlapping orange and green rectangles with the stripes.
Which again may work best with inkscape's renderer, but eventually chrome renders it faulty.



Hmm reading it again, switching off anti-aliasing cannot be done only on horizontal-vertical edges.
There is an extension to snap nodes to a px grid which theoretically can solve the problem but needs some try and error.

April 15, 2018, 08:56:08 AM
Reply #2

Zgred

  • Sr. Newbie

  • Offline
  • **

  • 3
...
There is an extension to snap nodes to a px grid which theoretically can solve the problem but needs some try and error.

That's exactly what I wanted.
Thank you very much   :2tu:
  • 0,92

April 15, 2018, 10:21:27 AM
Reply #3

Lazur

  • IC Mentor

  • Offline
  • ******
  • Inkscape Filters Wizard

  • 1,154
  • Gender
    Male

    Male