Package org.apache.poi.hwmf.record
Class HwmfBitmapDib
java.lang.Object
org.apache.poi.hwmf.record.HwmfBitmapDib
- All Implemented Interfaces:
GenericRecord
The DeviceIndependentBitmap Object defines an image in device-independent bitmap (DIB) format.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumstatic enum -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbyte[]getImage()static intprotected BufferedImageintinit(LittleEndianInputStream leis, int recordSize) booleanisValid()protected intprotected intprotected intreadRGBQuad(LittleEndianInputStream leis, int count) static voidsetMaxHeightWidth(int length) Adjust limit to prevent broken images from exceeding available memory when being drawn.toString()Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.apache.poi.common.usermodel.GenericRecord
getGenericChildren, getGenericRecordType
-
Constructor Details
-
HwmfBitmapDib
public HwmfBitmapDib()
-
-
Method Details
-
init
- Throws:
IOException
-
readHeader
-
readColors
- Throws:
IOException
-
readRGBQuad
- Throws:
IOException
-
isValid
public boolean isValid() -
getBMPStream
-
getBMPData
public byte[] getBMPData() -
getImage
-
getImage
-
toString
-
getGenericProperties
- Specified by:
getGenericPropertiesin interfaceGenericRecord
-
getPlaceholder
-
setMaxHeightWidth
public static void setMaxHeightWidth(int length) Adjust limit to prevent broken images from exceeding available memory when being drawn.- Parameters:
length- the max number of pixel of width/height to allow for images
-
getMaxHeightWidth
public static int getMaxHeightWidth()- Returns:
- the max number of pixel of width/height to allow for images
-