diff options
author | Fox Caminiti <fox@foxcam.net> | 2022-07-27 11:00:45 -0400 |
---|---|---|
committer | Fox Caminiti <fox@foxcam.net> | 2022-07-27 11:00:45 -0400 |
commit | 83ce428d8bb5f4a762abf879adec076bc34cf36a (patch) | |
tree | c1500f027d9eec514ba1a2912e7a4763e7be26b2 /main.h | |
parent | c6bd84c356b6aaa029b9708d7b99a4aba1673b6b (diff) |
full support for odd-dimension bitmaps and comps
Diffstat (limited to 'main.h')
-rw-r--r-- | main.h | 18 |
1 files changed, 14 insertions, 4 deletions
@@ -4,17 +4,25 @@ enum source_type { source_image }; +enum instruction_mode { + scalar_only, + sse_enabled, + avx_enabled +}; + struct pixel_buffer { void *OriginalBuffer; void *EffectBuffer; void *Scratch; uint16 Width; uint16 Height; + // IMPORTANT(fox): Since we're storing 4x4 chunks, I'm opting to pad out each + // dimension with an extra 1-3 pixels to make our lookup functions simpler. + // This has the cost of extra RAM, but it's a miniscule amount (0.2% extra + // data for a worst-case 1080p 16bpc frame, or 140 kb). + uint16 FullWidth; + uint16 FullHeight; uint16 Pitch; -#if PACKEDRGB -#else - uint32 Channel; -#endif uint16 BytesPerPixel; bool32 ToUpdate; // Set whenever effects or video frames need to be updated. }; @@ -246,6 +254,8 @@ struct transform_info { real32 YAxisPY; real32 LayerWidth; real32 LayerHeight; + uint32 FullLayerWidth; + uint32 FullLayerHeight; real32 LayerOpacity; real32 OriginX; real32 OriginY; |