Code example for InputStream

Methods: decodeStream

0
		decodeOptions.inJustDecodeBounds = true;
 
		InputStream in = null;
		try { 
			in = pAssetManager.open(pAssetPath);
			BitmapFactory.decodeStream(in, null, decodeOptions);
		} catch (final IOException e) {
			Debug.e("Failed loading Bitmap in AssetBitmapTextureAtlasSource. AssetPath: " + pAssetPath, e);
		} finally { 
			StreamUtils.close(in);
		} 
 
		return new AssetBitmapTextureAtlasSource(pAssetManager, pAssetPath, pTextureX, pTextureY, decodeOptions.outWidth, decodeOptions.outHeight);
	} 
 
	AssetBitmapTextureAtlasSource(final AssetManager pAssetManager, final String pAssetPath, final int pTextureX, final int pTextureY, final int pTextureWidth, final int pTextureHeight) {
		super(pTextureX, pTextureY, pTextureWidth, pTextureHeight);
 
		this.mAssetManager = pAssetManager;
		this.mAssetPath = pAssetPath;
Contextual code suggestions in your IDE  Get Codota for Java