Reputation: 11
I am confused about the usage of images in Xamarin. For iOS images I am using [email protected]. How does the image sizes relate to Android? I know Android doesn't like @2x in the image name. If I am skipping @2x and use sampleimage.png for Android then what common image name should I be using in PCL project.
Upvotes: 1
Views: 334
Reputation: 257
If you have an image named as icon_detail.
In resources file of ios project you should add three different sizes of this icon_detail image.
For example
first icon: 25*25 sizes => icon_detail.png
second icon: 50*50 sizes => [email protected]
third icon: 75*75 sizes => [email protected]
In android it is a little bit different
You should add icons with same name but different sizes.
For example
first icon : 25*25 sizes => icon_detail.png to drawable-hdpi file under resources
second icon : 50*50 sizes => icon_detail.png to drawable-xhdpi file under resources
third icon : 75*75 sizes => icon_detail.png to drawable-xxhdpi file under resources
Upvotes: 1