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.
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.
airdave said:your finished png/jpg must go back with the exact same outer dimension or it won't upload.
Why not create a white object with the exact pixel dimensions (same as the template), make sure it is perfectly aligned to the grid (test export to be sure), and then lock it.Then you can add objects on top of it (any size, any position, with or without outlines, aligned to the grid or not) and the template object should make sure that the exported image will be perfect in size.
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.
I did try white outline, and "no outline" (which I think is just "no colour", not really no outline).Neither made any difference, since Corel still adds the seen or unseen outline using the applied line thickness.
And the colour made no difference to the artwork, since the templates edges are well beyond the printing area.
Locking an object to the pixel grid is exactly what I wanted, but didn't know how to do.I will need to look into that.
Heres how I did it...exporting 54 separate artworks using the same template:
1. I created a new rectangle object in the correct pixel dimensions and reduced it by 1px on both sides (I also set the line thickness to 1px).2. On a new page, I turned on Pixel Grid/View and zoomed in...then positioned the new rectangle 'template', aligned to the pixel grid properly (checking all sides to be sure).3. Then I did a test export to check the new exported pixel dimensions (and it worked).4. Now I copied and pasted each artwork, onto the new page, positioned it roughly center in the rectangle template...then used the horizontal and vertical alignment tool (Align and Distribute Docker) to center the artwork in the rectangle.
*When aligning two objects, the last object placed is what will move to align with the first placed.So, even though the rectangle template is not 'locked' to the work area or pixel grid, it doesn't move when the objects are aligned.
5. So, after copy-pasting-aligning each artwork into the rectangle, I exported each as the png I needed in the correct pixel dimensions.
FYI - When I work, I always have a set of six Docker tabs to the right of my workspace. Things I use regularly and constantly in all my work...Shaping, Align & Distribute, Transformations, Contour, Envelope, Fillet/Scallop