• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

how to emulate a nexus 5 avd

 
Suzzane Pinto
Ranch Hand
Posts: 214
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi ,

i want to emulate a nexus 5 device in eclipse with 1920*1080 resolution and end up with a huge tablet like device.

Need help
 
Maneesh Godbole
Saloon Keeper
Posts: 11312
16
Android Eclipse IDE Google Web Toolkit Java Mac Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are you using Eclipse?
If yes Window->Android Virtual Device Manager -> Select AVD -> Edit -> Choose required device from the "Device" dropdown
 
Suzzane Pinto
Ranch Hand
Posts: 214
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
Thanks for the reply, the drop down does not have a device with 1920x1080 resolution so i went to device definitions and defined a new device with the necessary resolution then came to avd and selected that device...it emulated a very big 10' inch like device,probably not a nexus 5 device
 
Ulf Dittmer
Rancher
Posts: 42969
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If 1920x1080 is the resolution you want, but the size is too big, then you probably need to set a higher DPI value - probably xhdpi.
 
Suzzane Pinto
Ranch Hand
Posts: 214
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
1920*1080 is xxhdpi
 
Ulf Dittmer
Rancher
Posts: 42969
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
1920*1080 is a resolution - it does not have any DPI. The screen of a particular device has a DPI (and can thus be xhdpi or xxhdpi). Did you set the device to xxhdpi when you created it?
 
Suzzane Pinto
Ranch Hand
Posts: 214
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I defined the resolution 1920x1080 in device definitions ,it automatically took the density as xxhdpi
 
Steve Luke
Bartender
Posts: 4181
22
IntelliJ IDE Java Python
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is probably because the monitor doesn't have the density of the phone... for example my 24" monitor is 1920x1080 resolution, but that is way less density than the Nexus 5 - so the screen of the Nexus 5 emulator would be about as big as my monitor. When you launch the AVD you will have to check the option to scale the screen - this will change the actual number of pixels in the AVD's display to match the physical size of the device displayed on your monitor. Note: because of the scaling you won't get the true density of the Nexus 5, the correct resources will be loaded but they won't look as crisp. If you really need to see the density/crispness of your graphics you will need to not scale - and work with the larger display. And if you are concerned with both the physical layout and the density you either need to use switch between multiple AVDs (one with scaling one without) or use a physical device with approximately the same dimensions and density - largertablets can be used for this as long as it is sufficiently dense... see http://www.androidcentral.com/use-nexus-10-simulate-almost-any-android-device-while-testing-your-app )
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic