projects/syncslides/app/src/main/java/io/v/android/apps/syncslides/model/DeckFactory.java
/**
     * Decodes raw image data from the given resource.  Returns empty data on error.
     */
Decodes raw image data from the given resource.  Returns empty data on error.
Decodes raw image data from the given resource . Returns empty data on error .
public static byte[] imageDataFromResource(Context c, int id) {
        try {
            return ByteStreams.toByteArray(c.getResources().openRawResource(id));
        } catch (IOException e) {
            Log.e(TAG, "Error reading image data from resource: " + e.getMessage());
            return new byte[0];
        }
    }
public static byte [ ] imageDataFromResource ( Context c , int id ) { try { return ByteStreams . toByteArray ( c . getResources ( ) . openRawResource ( id ) ) ; } catch ( IOException e ) { Log . e ( TAG , "Error reading image data from resource: " + e . getMessage ( ) ) ; return new byte [ 0 ] ; } }
Decodes raw image data from the given resource.
Decodes raw image data from the given resource .