Changeset View
Changeset View
Standalone View
Standalone View
source/blender/makesdna/DNA_ID.h
| Show First 20 Lines • Show All 149 Lines • ▼ Show 20 Lines | typedef struct Library { | ||||
| struct Library *parent; /* set for indirectly linked libs, used in the outliner and while reading */ | struct Library *parent; /* set for indirectly linked libs, used in the outliner and while reading */ | ||||
| struct PackedFile *packedfile; | struct PackedFile *packedfile; | ||||
| } Library; | } Library; | ||||
| enum eIconSizes { | enum eIconSizes { | ||||
| ICON_SIZE_ICON = 0, | ICON_SIZE_ICON = 0, | ||||
| ICON_SIZE_PREVIEW = 1 | ICON_SIZE_PREVIEW = 1, | ||||
| NUM_ICON_SIZES | |||||
| }; | |||||
| /* for PreviewImage->flag */ | |||||
| enum ePreviewImage_Flag { | |||||
| PRV_CHANGED = (1 << 0), | |||||
| PRV_USER_EDITED = (1 << 1), /* if user-edited, do not auto-update this anymore! */ | |||||
| }; | }; | ||||
| #define NUM_ICON_SIZES (ICON_SIZE_PREVIEW + 1) | |||||
| typedef struct PreviewImage { | typedef struct PreviewImage { | ||||
| /* All values of 2 are really NUM_ICON_SIZES */ | /* All values of 2 are really NUM_ICON_SIZES */ | ||||
| unsigned int w[2]; | unsigned int w[2]; | ||||
| unsigned int h[2]; | unsigned int h[2]; | ||||
| short changed[2]; | short flag[2]; | ||||
| short changed_timestamp[2]; | short changed_timestamp[2]; | ||||
| unsigned int *rect[2]; | unsigned int *rect[2]; | ||||
| /* Runtime-only data. */ | |||||
| struct GPUTexture *gputexture[2]; | struct GPUTexture *gputexture[2]; | ||||
| int icon_id; /* Used by previews outside of ID context. */ | |||||
| char pad[3]; | |||||
| char use_deferred; /* for now a mere bool, if we add more deferred loading methods we can switch to bitflag. */ | |||||
| } PreviewImage; | } PreviewImage; | ||||
| #define PRV_DEFERRED_DATA(prv) \ | |||||
| (CHECK_TYPE_INLINE(prv, PreviewImage *), BLI_assert((prv)->use_deferred), (void *)((prv) + 1)) | |||||
| /** | /** | ||||
| * Defines for working with IDs. | * Defines for working with IDs. | ||||
| * | * | ||||
| * The tags represent types! This is a dirty way of enabling RTTI. The | * The tags represent types! This is a dirty way of enabling RTTI. The | ||||
| * sig_byte end endian defines aren't really used much. | * sig_byte end endian defines aren't really used much. | ||||
| * | * | ||||
| **/ | **/ | ||||
| ▲ Show 20 Lines • Show All 102 Lines • Show Last 20 Lines | |||||