Class is used for getting bitmaps (png, jpg, svg) from byte array. More...
#include <com/navigine/idl/objc/NCBitmapRegionDecoder.h>
Inherits NSObject.
Instance Methods | |
| (nullable UIImage *) | - decodeRegion:sampleSize: |
| Method is used to decode rectangle region in the image specified by rect. | |
Class Methods | |
| (nullable NCBitmapRegionDecoder *) | + newInstance: |
| Method is used to create instance of BitmapRegionDecoder. | |
| (nullable NCBitmapRegionDecoder *) | + newInstanceFromImage: |
| Creates decoder from Image without copying raw bytes again. | |
Properties | |
| int32_t | width |
| Width of the source image in pixels (after header parse / decode metadata). | |
| int32_t | height |
| Height of the source image in pixels (after header parse / decode metadata). | |
| BOOL | valid |
Class is used for getting bitmaps (png, jpg, svg) from byte array.
Definition at line 19 of file NCBitmapRegionDecoder.h.
| - (nullable UIImage *) decodeRegion: | (nonnull NCRectangle *) | rect | |
| sampleSize: | (float) | sampleSize |
Method is used to decode rectangle region in the image specified by rect.
| rect | area to render Rectangle |
| sampleSize | if set to a value > 1, requests the decoder to subsample the original image, returning a smaller image to save memory. |
Swift code snippet:
Objective C code snippet:
| + (nullable NCBitmapRegionDecoder *) newInstance: | (nonnull NSData *) | data |
Method is used to create instance of BitmapRegionDecoder.
| data | raw image data (could be raw svg string) |
Swift code snippet:
Objective C code snippet:
| + (nullable NCBitmapRegionDecoder *) newInstanceFromImage: | (nullable NCImage *) | data |
Creates decoder from Image without copying raw bytes again.
| data | image instance (e.g. from SDK pipeline); must remain valid while decoder is used |
Swift code snippet:
Objective C code snippet:
|
readnonatomicassign |
Height of the source image in pixels (after header parse / decode metadata).
Swift code snippet:
Objective C code snippet:
Definition at line 102 of file NCBitmapRegionDecoder.h.
|
readnonatomicassign |
Tells if this object is valid or not. Any method called on an invalid object will throw an exception. The object becomes invalid only on UI thread, and only when its implementation depends on objects already destroyed by now.
Definition at line 110 of file NCBitmapRegionDecoder.h.
|
readnonatomicassign |
Width of the source image in pixels (after header parse / decode metadata).
Swift code snippet:
Objective C code snippet:
Definition at line 87 of file NCBitmapRegionDecoder.h.