Image Asset Studio helps you to generate custom icons for your Android applications from existing
+ image, clipart, or text-string resources. It generates a set of icons at the appropriate resolution
+ for each generalized screen
+ density that your app supports.
+ The newly generated icons are placed in density-specific folders (for example, mipmap-mdpi/
+ or drawable-xxxhdpi/), which
+ reside in the application’s res/ folder. At runtime, Android uses the appropriate
+ resource based on the screen density of the device your application is running on.
+
+
Image Asset Studio generates the following asset types:
+
+
Launcher icons.
+
Action bar and tab icons.
+
Notification icons.
+
+
+
This guide shows how to generate these assets using Image Asset Studio.
+
+
Accessing Image Asset Studio
+
Follow these steps to access Image Asset Studio:
+
+
In Android Studio, open an Android app project.
+
In the project-view-pane
+ on the left side of the screen, select Android from the dropdown menu. The Android
+ project view appears in the pane.
+
+
Right-click the res/folder and select New > Image
+Asset. The Image Asset Studio window appears.
+
+
+
+
Creating Icons
+
You can generate icons from image, clipart
+, or text-string resources. This section explains how to work with
+each of these resources.
+
+
+
+
From an image resource
+
+
Open the Asset Type dropdown menu and select an icon type.
+
From the available Foreground options, select Image.
+
Specify the asset to use by entering a filename in the Image file field or by
+ navigating to and selecting a file via the file browser. Image Asset Studio supports the following
+ file types, in descending order of desirability: PNG, JPG, and GIF.
+
The icon to be generated appears in the Preview pane, displayed at sizes corresponding
+ to different screen densities.
+
+
The rest of the settings on this screen are optional.
+To learn how to customize your icons using these options,
+ see Customizing Icons.
Image Asset Studio lets you customize various visual effects for your icons. The following options
+are of particular note.
+
+
+
Trim surrounding blank space: This option allows you to adjust the margin between the
+icon graphic and border.
+
+
+ Figure 1: An icon before and after trimming.
+
+
Additional Padding: This option allows you to adjust the icon's padding on all four
+sides. Use the slider to select a value between 0 and 100 pixels. For example, for a 100px X 100px
+image with padding of 25px, the resulting image is 150px X 150px.
+
Theme: This option allows you to set a theme for your action bar and tab icons.
+ You can tint icons using the HOLO_DARK or HOLO_LIGHT theme or create
+ a custom theme using the color palette.
+
Resource name: This option allows you to specify a resource name other than the
+ default one. If an asset with the specified resource name already exists, Image Asset Studio warns
+ you that it is going to overwrite the existing asset with this one.
+
+
+
Saving Icons
+
This section explains how to save your icons to the res/ folder. Do so by following
+ these steps:
+
+
From the initial screen that appeared when you opened Image Asset Studio, click
+ Next. Image Asset Studio opens a new window.
+
Confirm the target module and resource directory settings for the icon.
+ If you don't want to use the default target module or resource directory, you can
+ enter your own values for them.
+
+
Click Finish. The Image Asset Studio generates new icon files, in PNG format,
+ according to the options you have chosen.
+
+
+
+
Note: Launcher icon files reside in a different location from that
+ of other icons. They are located in the mipmap/ folder. All other icon files reside
+ in the drawable/ folder of your project.
+
+
+
Configuring Build Properties
+
To change the module and resource directory, follow these steps:
+
+
In the Target Module field, select a module to add the resource to.
+For more information,
+see
+Creating an Android Module.
+
+
In the Res Directory field, select an option for where to place the image
+ asset:
+
+
src/main/res: This source set applies to all build variants, including debug
+ and release.
+
src/debug/res, src/release/res: These source sets override the main
+ source set and apply to one version of a build. The debug source set is for debugging only.
+
+
User-defined: To define your own source set, select File > Project
+ Structure > app > Build Types.
+ For example, you could define a beta source set and create a version of an icon that includes the
+ text "BETA” in the bottom right corner. For more information, see
+
+ Work with build variants.
+
+
+
+
+
+
+
Referring to an Image Resource in Code
+
+
After you have an image resource in the res/directory of your project, you can
+ reference it from your Java code or your XML layout using its
+
+ resource ID.
+
+
For example, the following XML references the ic_launcher icon in the
+mipmap/ folder.
diff --git a/docs/html/tools/help/index.jd b/docs/html/tools/help/index.jd
index f984f2e8ce653..86c10354c4089 100755
--- a/docs/html/tools/help/index.jd
+++ b/docs/html/tools/help/index.jd
@@ -133,7 +133,13 @@ files after they have been signed.
WYSIWYG editor. It also previews stretched versions of the image, and highlights the area in which
content is allowed.
-
Helps you to generate custom icons for your Android applications from existing images, cliparts, or text.
+ It generates a set of icons at the appropriate resolution for each generalized screen density that your app
+ supports.