|
|
@@ -19,18 +19,20 @@ namespace oxygine
|
|
|
flag_fixedBounds = 1 << 3,
|
|
|
};
|
|
|
|
|
|
- PostProcessOptions(int flags = 0) : _flags(flags), _downscale(1), _clearColor(0, 0, 0, 0) {}
|
|
|
+ PostProcessOptions(int flags = 0) : _flags(flags), _downscale(1), _clearColor(0, 0, 0, 0), _format(TF_R4G4B4A4) {}
|
|
|
PostProcessOptions& fullscreen(bool enable = true) { _flags = enable ? (_flags | flag_fullscreen) : (_flags & (~flag_fullscreen)); return *this; }
|
|
|
PostProcessOptions& singleRender(bool enable = true) { _flags = enable ? (_flags | flag_singleR2T) : (_flags & (~flag_singleR2T)); return *this; }
|
|
|
//loops -(2, 3, 4, ...), final size: 2^loops
|
|
|
PostProcessOptions& downscale(int loops = 2) { _downscale = loops; return *this; }
|
|
|
PostProcessOptions& clear(const Color& c) { _clearColor = c; return *this; }
|
|
|
PostProcessOptions& fixedBounds(const RectF& b) { _fixedBounds = b; _flags |= flag_fixedBounds; return *this; }
|
|
|
+ PostProcessOptions& format(TextureFormat tf) { _format = tf; return *this; }
|
|
|
|
|
|
int _flags;
|
|
|
int _downscale;
|
|
|
RectF _fixedBounds;
|
|
|
Color _clearColor;
|
|
|
+ TextureFormat _format;
|
|
|
};
|
|
|
|
|
|
|
|
|
@@ -127,4 +129,4 @@ namespace oxygine
|
|
|
void addPostProcessItem(PPTask*);
|
|
|
void removePostProcessItem(PPTask*);
|
|
|
void clearPostProcessItems();
|
|
|
-}
|
|
|
+}
|