I need to retrieve the height and width of uploaded image using App Engine BlobStore. For finding that i used following code :
try {
Image im = ImagesServiceFactory.makeImageFromBlob(blobKey);
if (im.getHeight() == ht && im.getWidth() == wd) {
flag = true;
}
} catch (UnsupportedOperationException e) {
}
i can upload the image and generate the BlobKey but when pass the Blobkey to makeImageFromBlob(), it generate the following error:
java.lang.UnsupportedOperationException: No image data is available
How to solve this problem or any other way to find image height and width directly from BlobKey.