I can get contact’s badge using next function in Android:
[java] public Bitmap getContactBadge(int id) {
Uri uri = ContentUris.withAppendedId(Contacts.CONTENT_URI, id);
InputStream input = Contacts.openContactPhotoInputStream(getContentResolver(), uri);
if (input == null) {
return null;
}
return BitmapFactory.decodeStream(input);
}[/java]
On jME side I have form which consist information about particular contact. This form is described in xml file.
My question is: How can I load contact’s badge which I have on Android to NiftyImage on jME side?
I know the way how to set static image from asset:
[java]NiftyImage img = nifty.getRenderEngine().createImage(“Textures/dirt.jpg”, false);[/java]