Entities
entities/ raster
#include "dxfio/entities/raster.hpp"In DxfIO::Entities
struct Pixel
A vertex of the clipping boundary of an image or a wipeout.
| Field | Type | Meaning |
|---|---|---|
Position | Vector | The vertex, in pixels of the image. Groups 14, 24. |
struct Raster
What an IMAGE and a WIPEOUT share: where the picture lies, how it is shown and how it is clipped.
| Field | Type and default | Meaning |
|---|---|---|
Version | int | The version of the image's layout. Group 90. |
Origin | Vector | The insertion point, the outer corner of the bottom-left pixel, in world coordinates. Groups 10, 20, 30. |
Across | Vector | One pixel's step along the bottom edge of the image, in world coordinates. Groups 11, 21, 31. |
Down | Vector | One pixel's step up the left edge of the image, from the insertion point, in world coordinates. Groups 12, 22, 32. |
Size | Vector | The width and height of the image, in pixels. Groups 13, 23. |
Definition | Handle | The IMAGEDEF that names the picture's file. Group 340. |
Flags | int{Displayed} | 1 shown, 2 shown when not aligned with the screen, 4 clipped, 8 transparent; 7 for a new one, as AutoCAD writes it. Group 70. |
Clipped | int | Whether the clipping boundary is on. Group 280. |
Brightness | int{Halfway} | The brightness, 0 to 100. Group 281. |
Contrast | int{Halfway} | The contrast, 0 to 100. Group 282. |
Fade | int | The fade, 0 to 100. Group 283. |
Outside | bool | Whether the clip is inverted, hiding what lies inside the boundary. Group 290, from R2010. |
Reactor | Handle | The IMAGEDEF_REACTOR that ties the image to its definition. Group 360. |
Kind | int{1} | The shape of the clipping boundary: 1 a rectangle, as for a new one, 2 a polygon. Group 71. |
Corners | std::vector<Pixel> | The vertices of the clipping boundary, two opposite corners for a rectangle; group 91 counts them. |
struct ImageIMAGE
An IMAGE: a raster picture placed in the drawing, its file named by an IMAGEDEF.
| Field | Type | Meaning |
|---|---|---|
Record | Entities::Record | The layer, linetype, color and the rest every entity carries. |
Picture | std::string | The proxy graphics, for programs that cannot draw the entity. Group 92, or 160 from R2010, then 310. |
Raster | Boxed<Entities::Raster> | Where the picture lies, how it is shown and how it is clipped, from the AcDbRasterImage subclass. |
struct WipeoutWIPEOUT
A WIPEOUT: an area that hides what is drawn under it, laid out as an image.
| Field | Type | Meaning |
|---|---|---|
Record | Entities::Record | The layer, linetype, color and the rest every entity carries. |
Picture | std::string | The proxy graphics, for programs that cannot draw the entity. Group 92, or 160 from R2010, then 310. |
Raster | Boxed<Entities::Raster> | Where the area lies and the boundary that shapes it, from the AcDbWipeout subclass. |
Constants
Displayed | int = 7 | The display flags of a new image or wipeout, as AutoCAD writes them: shown, shown when not aligned with the screen, and clipped. |
Halfway | int = 50 | The brightness and the contrast of a new image or wipeout: 50, halfway, as AutoCAD writes them. |