diff options
author | Clément Foucault <foucault.clem@gmail.com> | 2018-10-09 18:32:13 +0300 |
---|---|---|
committer | Clément Foucault <foucault.clem@gmail.com> | 2018-10-09 18:34:04 +0300 |
commit | e234ce9b2272323ef2666d3f0718ecb8c688b693 (patch) | |
tree | 44b5d18a5fb306b747791671239d9c48ac434d4c /source/blender/draw/intern/draw_manager.h | |
parent | 6d6e3869ce52085bbd4351de96cbc0e6b51b974b (diff) |
Eevee: Add support/Fix Object Info node
Caveat: Random output does not yet work with instance (dupli) objects.
Diffstat (limited to 'source/blender/draw/intern/draw_manager.h')
-rw-r--r-- | source/blender/draw/intern/draw_manager.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/source/blender/draw/intern/draw_manager.h b/source/blender/draw/intern/draw_manager.h index 5916b45aa27..bba98f5e102 100644 --- a/source/blender/draw/intern/draw_manager.h +++ b/source/blender/draw/intern/draw_manager.h @@ -101,6 +101,7 @@ enum { DRW_CALL_NORMALWORLD = (1 << 5), DRW_CALL_ORCOTEXFAC = (1 << 6), DRW_CALL_EYEVEC = (1 << 7), + DRW_CALL_OBJECTINFO = (1 << 8), }; typedef struct DRWCallState { @@ -122,6 +123,7 @@ typedef struct DRWCallState { float normalview[3][3]; float normalworld[3][3]; /* Not view dependent */ float orcotexfac[2][3]; /* Not view dependent */ + float objectinfo[2]; float eyevec[3]; } DRWCallState; @@ -140,6 +142,7 @@ typedef struct DRWCall { union { struct { /* type == DRW_CALL_SINGLE */ GPUBatch *geometry; + short ma_index; } single; struct { /* type == DRW_CALL_RANGE */ GPUBatch *geometry; @@ -257,6 +260,7 @@ struct DRWShadingGroup { int orcotexfac; int eye; int callid; + int objectinfo; uint16_t matflag; /* Matrices needed, same as DRWCall.flag */ #ifndef NDEBUG |