Had this problem forever, only the project I am currently working on, its a critical issue...
I'm currently exporting some vector art as a png file to be printed later. (I've also exported as jpg, same issue).And, this applies to exporting the same art from Draw or Paint.
The entire image is clearly checked to be the required pixel dimensions, and yet the saved file is always 1-2px larger (both axis).I can draw a simple outline box, any colour outline, any thickness outline, even invisible outline...set the pixel dimensions...and export...and the saved image will be 1-2px larger.
I have to pre-think, and reduce the border dimensions by at least 1px (both directions) for the saved image to be the correct pixel dimensions I need.
Why is this?I remember seeing this in previous verions of Corel, and as I said, I can export as png or jpg...I can also copy the art into Paint, and then export as.The end result is the same.
try to look here
https://community.coreldraw.com/talk/coreldraw_graphics_suite_x6/f/coreldraw-graphics-suite-x6/39545/pixel-view
Is your graphic alligned to pixel grid?
I don't know how to do that in Draw.I know in Paint, you can zoom in and see the pixels...
I'm not sure how that should matter though, since line thickness is set to less than a pixel width.I even tried no outline.
But then I read (in your link) that outlines are not included in object dimensions.Meaning, they are added during save...so at least 1px must be added (depending on outline thickness).
And if pixel grid affects it, it might add another pixel to the size.
Regardless, I guess the solution is to do what I have always done: guess.Guess and reduce my object by 1 or 2 pixel to compensate for the outline during save.
Thanks for you input!
Make sure that the objects are exactly full pixels in size, no decimals.Enable "Snap to Pixels", switch to Pixels view mode in Draw to make sure the objects get perfectly aligned with the pixel grid on all four sides.You may also enable "Object Hinting" to help get the objects in place.
Thanks Mek and Ronny
Snap to Pixel is useless, doesn't work.At least not in my buggy version of Corel..
Speaking of buggy, Corel froze about 16 times while attempting to export pngs yesterday.Never had it this bad until messing around with this pixel view/snap, etc
Funny that you have to turn on pixel 'view' every time you open a file, and yet other view styles stay in place when you close and reopen a file...?
Eventually I got all my images done by placing my boundary object on a pixel view and lining it up directly on a single pixel alignment. As I said, 'snap to pixel' didn't always work, and although one corner might seem to snap to a single pixel, the other sides of the object didn't always line up and I would have to shift the object half a pixel.
I set the object to 1px line thickness (.24pt) just to be sure.
As I said earlier, the pixel alignment didn't matter since CorelDraw does not include that 1-2px extra constituted by the boundary outline. (*this is proven by whatever the line thickness, the object dimensions stay the same)So you must always factor this in (when saving to image file) by adding the extra pixels covered by the boundary outline*.In my case, I had to add 1px to every side of a rectangle to get the correct image size.
*this makes no sense if you choose "no outline" which is what I was using at first.
airdave said:Snap to Pixel is useless, doesn't work.
airdave said:although one corner might seem to snap to a single pixel, the other sides of the object didn't always line up
It should only snap to pixel edges and centers as far as I know.If one side is aligned, the opposite side should be too, IF the object's dimensions are full size pixels.One problem that I found now when checking Draw 2018, is that it doesn't seem to show pixel decimals in Property Bar (while Draw 2020 does).If that is the case, you must manually type in ".0" in the size boxes to make sure the size is correct.
airdave said:I set the object to 1px line thickness (.24pt) just to be sure.
If you add a 1 pt (center positioned) outline, you also add half a pixel on each side, which makes the object move away from the grid and it adds two pixels to the exported image.If you move the object half a pixel right and down, the object's outline will be aligned with the grid but you will still get one extra pixel when exporting.So, if you use centered or outside outlines, you must calculate for the extra width and height.That's how it is unfortunately.
agreed, agreed, agreed.
I've never put pixels in as line thickness before...it makes some sense when working in pixel dimensions, but why does Corel stay in pt measure then?
And when I entered "1px", and it showed .24pt, I really wondered if that was going to work...and as you say, its the portion of a pt that messes things up.
As long as the object is an exact pixel dimension (not a fraction) it can be positioned on the pixel grid,but as you say, it must be properly aligned on one side...which I did manually/by-eye rather than rely on the snap-to-pixel.
And yes, regarding an exact pixel dimension output (if it is required) you have to calculate in the extra pixels for the outline (that Corel does not recognize!) lol.
Thanks again for the input.