OK, I'm close to tearing out what little hair I have left, so somebody tell me if I'm crazy.
I have my Inkscape default resolution when exporting to bitmap set to 150 dpi.
When I start a new document, I set the size of the image to be 8x22 inches.
Why in the world (read that: WHY IN THE @#$*&#$@*&% WORLD) is the image 1980x720 px in size? That's what I'd expect for a 90dpi export. Is it reflecting my screen resolution? But that's 96dpi, not 90. But the rulers on the screen are pretty clear that this thing is 1980x720.
What the willy-nilly gee-dang heck is going on?
Can't wait to be shocked at how blindingly obvious the answer is.
Tom
Determining print size
-
- Posts: 626
- Joined: Wed Jun 06, 2007 2:37 am
Re: Determining print size
the simple answer is that the dpi of a doc is generally assumed to be 90pi in various places in the inkscape code. the export setting I believe purely relates to export. The resolution one isnt picked up, and 90 is hard coded in various places. Its a semi evil that we know about. (the 90 comes from the spec as the value to fall back to I believe, may be wrong tho)
One of those things thats been there since day one, that no one has got round to changing I'm afraid.
One of those things thats been there since day one, that no one has got round to changing I'm afraid.
Re: Determining print size
Units can be quite confusing, its a bit too late in the day to give a complete and sane explanation (makes me dizzy in the head) so Ill just try this:
While open in Inkscape the image will show its size according to 90dpi resolution that it (as I understand) a default for Inkscape. This is what the numbers in the top part of the Export Bitmap dialog mean > just the size of the image in 90dpi. When you create a new document you can only set its size but not resolution, Inkscape assumes 90dpi.
While exporting bitmap you set a different resolution (using Export Bitmap dialog > Bitmap size) and that is the resolution that determines the final size of your exported .png, and will not match the size you see on rulers inside Inkscape (unless the exporting res is 90dpi that Inkscape uses as default). In your example; 8x22in will be 720x1980px inside Inkscape, but when you export it in 150dpi the size of the final .png will be 1200x3300px, try it and see
btw why use 150dpi? Its too much for screen and too little for print
While open in Inkscape the image will show its size according to 90dpi resolution that it (as I understand) a default for Inkscape. This is what the numbers in the top part of the Export Bitmap dialog mean > just the size of the image in 90dpi. When you create a new document you can only set its size but not resolution, Inkscape assumes 90dpi.
While exporting bitmap you set a different resolution (using Export Bitmap dialog > Bitmap size) and that is the resolution that determines the final size of your exported .png, and will not match the size you see on rulers inside Inkscape (unless the exporting res is 90dpi that Inkscape uses as default). In your example; 8x22in will be 720x1980px inside Inkscape, but when you export it in 150dpi the size of the final .png will be 1200x3300px, try it and see
btw why use 150dpi? Its too much for screen and too little for print
just hand over the chocolate and nobody gets hurt
Inkscape Manual on Floss
Inkscape FAQ
very comprehensive Inkscape guide
Inkscape 0.48 Illustrator's Cookbook - 109 recipes to learn and explore Inkscape - with SVG examples to download
Inkscape Manual on Floss
Inkscape FAQ
very comprehensive Inkscape guide
Inkscape 0.48 Illustrator's Cookbook - 109 recipes to learn and explore Inkscape - with SVG examples to download
Re: Determining print size
Thanks for the replies.
I realize that dpi isn't something that matters when you're drawing - seems like Inkscape just wants you to draw in all the details you want and then print at whatever SIZE you want, with raw dpi being less important. Mmkay. For a newbie like me, particularly one who's coming from the raster graphics world like Paintshop Pro, it's an unfortunate shift in thinking - one of the first things you set in a new drawing is the dpi, and it's hard to get away from that. Shrug.
There actually is a way to tweak it to my liking - modify the number of pixels per linear unit in the Inkscape\share\ui\units.xml file. Easy to change it from 90 to 150 or whatever you want. Yes, it's ultimately irrelevant to the dpi that you export the bitmap at, but while drawing, it gives me some peace of mind to see Inkscape assign 1500x3000 pixels to my 10"x20" 150dpi drawing. Just removes an annoyance in my cluttered mind.
Why 150dpi? This is a boardgame map, and 150 seems to have enough resolution. Kind of an interesting problem we have with these - the games can also be played online using the VASSAL game engine (http://www.vassalengine.org), and those maps are 72dpi gifs. It would be wonderful to not have to draw two separate versions of the map (one hardcopy for face-to-face play and one electronic for online play) but Inkscape doesn't have the option of rendering to a limited set of colors - it always antialiases. If there was some way to limit the color space that Inkscape renders into, that would be fabulous because the online version of the game depends heavily on the maps having a predefined set of RGB triplets in order to let Java operate on them in particular ways. For instance, if a scenario is set in the winter and there's snow, Java can take a particular RGB triplet for the green grass and change it to white - voila, instant snow. Very cool.
At any rate. Thanks for the help.
Tom
I realize that dpi isn't something that matters when you're drawing - seems like Inkscape just wants you to draw in all the details you want and then print at whatever SIZE you want, with raw dpi being less important. Mmkay. For a newbie like me, particularly one who's coming from the raster graphics world like Paintshop Pro, it's an unfortunate shift in thinking - one of the first things you set in a new drawing is the dpi, and it's hard to get away from that. Shrug.
There actually is a way to tweak it to my liking - modify the number of pixels per linear unit in the Inkscape\share\ui\units.xml file. Easy to change it from 90 to 150 or whatever you want. Yes, it's ultimately irrelevant to the dpi that you export the bitmap at, but while drawing, it gives me some peace of mind to see Inkscape assign 1500x3000 pixels to my 10"x20" 150dpi drawing. Just removes an annoyance in my cluttered mind.
Why 150dpi? This is a boardgame map, and 150 seems to have enough resolution. Kind of an interesting problem we have with these - the games can also be played online using the VASSAL game engine (http://www.vassalengine.org), and those maps are 72dpi gifs. It would be wonderful to not have to draw two separate versions of the map (one hardcopy for face-to-face play and one electronic for online play) but Inkscape doesn't have the option of rendering to a limited set of colors - it always antialiases. If there was some way to limit the color space that Inkscape renders into, that would be fabulous because the online version of the game depends heavily on the maps having a predefined set of RGB triplets in order to let Java operate on them in particular ways. For instance, if a scenario is set in the winter and there's snow, Java can take a particular RGB triplet for the green grass and change it to white - voila, instant snow. Very cool.
At any rate. Thanks for the help.
Tom
Re: Determining print size
Im glad you found a way to tweak the settings, there are things you can change manually that don't have UI yet, but it will surely come in the following versions. Color management is coming in the 0.46
If you have the skills you can help develop that part of Inkscape and speed it up a bit
If you have the skills you can help develop that part of Inkscape and speed it up a bit
just hand over the chocolate and nobody gets hurt
Inkscape Manual on Floss
Inkscape FAQ
very comprehensive Inkscape guide
Inkscape 0.48 Illustrator's Cookbook - 109 recipes to learn and explore Inkscape - with SVG examples to download
Inkscape Manual on Floss
Inkscape FAQ
very comprehensive Inkscape guide
Inkscape 0.48 Illustrator's Cookbook - 109 recipes to learn and explore Inkscape - with SVG examples to download
Re: Determining print size
tuomo wrote:it's an unfortunate shift in thinking - one of the first things you set in a new drawing is the dpi, and it's hard to get away from that.
Yeah, I'm the same. And think this value is quite significant when printing. I don't print much, so it was only yesterday that I realised I couldn't control the print resolution or size. This is something that normally links back to the document properties. In the end I exported the image at a high resolution and printed from a raster application.
Re: Determining print size
I've never had to print directly from Inkscape so I didn't even notice it before but theres an option Print Direct under File menu where you can choose dpi while printing as bitmap (you can control the size in Document properties). Im not sure if this is available in 0.45
just hand over the chocolate and nobody gets hurt
Inkscape Manual on Floss
Inkscape FAQ
very comprehensive Inkscape guide
Inkscape 0.48 Illustrator's Cookbook - 109 recipes to learn and explore Inkscape - with SVG examples to download
Inkscape Manual on Floss
Inkscape FAQ
very comprehensive Inkscape guide
Inkscape 0.48 Illustrator's Cookbook - 109 recipes to learn and explore Inkscape - with SVG examples to download
Re: Determining print size
Kind of an epilogue to the story - I measured out exactly how big I wanted my map to print at (it's gotta be the same size as existing maps for this game), so I converted that (21 and 29/32 by 7 and 31/32 inches, just to show how anal I am) to 150 dpi and scaled my Inkscape document to that size. Then went to export the thing and bam - wrong size. Even with the units.xml file tweaked, Inkscape is apparently hardcoded in other places to mandate 90dpi (just like others have said). OK, so you take your desired output size in inches and multiply by 90dpi to get the size it should be in Inkscape. Then export at whatever dpi you want and everything comes out fine.
THEN the Black Art of printing comes into play. Import the png file into GIMP, check that it's the right size, then print (making sure there's no funky scaling going on in my laser printer's settings) and the thing comes out just a smidge too small. Ended up scaling the thing to 101% to get the size I wanted.
So. Moral of the story is the same as its always been. You take care of the things you can (setting the size in Inkscape correctly), then you deal with the inevitable boogums.
Tom
THEN the Black Art of printing comes into play. Import the png file into GIMP, check that it's the right size, then print (making sure there's no funky scaling going on in my laser printer's settings) and the thing comes out just a smidge too small. Ended up scaling the thing to 101% to get the size I wanted.
So. Moral of the story is the same as its always been. You take care of the things you can (setting the size in Inkscape correctly), then you deal with the inevitable boogums.
Tom
Re: Determining print size
prkos wrote:I've never had to print directly from Inkscape so I didn't even notice it before but theres an option Print Direct under File menu where you can choose dpi while printing as bitmap (you can control the size in Document properties). Im not sure if this is available in 0.45
Thanks for pointing that out. I seen that option but assumed it was a method to quickly print without getting the printer dialog.