R
R
rmkk2016-11-11 16:05:33
User interface
rmkk, 2016-11-11 16:05:33

How to change ppi to dpi when exporting from illustrator (and is it necessary)?

There is a task: to make an icon in several sizes (see picture)
1c75b98afb604d80bd141f58beba28d5.png
I'm trying to export from illustrator, but there is an option to set only ppi
e67a2c5ea07f4978a7c2c655ccb49498.png
1. Is it possible to change ppi to dpi?
2. Is the difference fundamental in my case (see the requirements in the picture above)

Answer the question

In order to leave comments, you need to log in

2 answer(s)
G
GreatRash, 2016-11-11
@GreatRash

::rukalitso:: the dimensions are written in pixels right there, do it in pixels, why are you inventing difficulties for yourself?

N
Neron, 2016-11-11
Lordov @Nekto_Habr

1dpi: 120 dpi <-> 72 ppi
mdpi: 160 dpi <-> 96 ppi
hdpi: 240 dpi <-> 144 ppi
xhdpi: 320 dpi <-> 192 ppi
The principle is simple. We draw an icon for 1dpi in pixels (36x36 px). To get the same size in pixels when exporting, ppi will be the default, that is, 72. Knowing that 1dpi = 120 dpi, you can calculate the coefficient by which you should multiply the original ppi (72) to get mdpi, hdpi, xhdpi:
For example, take xhdpi (320dpi). We divide it by 1dpi (120 dpi), we get 2 integers and 2/3 (~ 2.66666667). We multiply by this resulting coefficient 72:
2.66666667 * 72 \u003d 192
All this non-obvious hemorrhoids probably arose due to the fact that there are two types of "default ppi" - 72 and 96. Accordingly, in the guides they simply took and invented their own bicycle so as not to depend on these values.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question