aboutsummaryrefslogtreecommitdiff
path: root/src/sfml/graphics/BlendMode.zig
diff options
context:
space:
mode:
authortslil clingman <>2021-10-30 16:54:03 -0400
committertslil clingman <>2021-10-30 16:56:41 -0400
commit6ead90c0f0e9b9a44c7c1f7137f437faa29fa750 (patch)
tree38cbaff4f606689a149865d5708dadac47ee43db /src/sfml/graphics/BlendMode.zig
parent48dee0817f5fe8c09a085f0150e0c6b4a699ab7c (diff)
Switched to tracking zig-sfml-wrapper as submodule
Diffstat (limited to 'src/sfml/graphics/BlendMode.zig')
-rw-r--r--src/sfml/graphics/BlendMode.zig92
1 files changed, 0 insertions, 92 deletions
diff --git a/src/sfml/graphics/BlendMode.zig b/src/sfml/graphics/BlendMode.zig
deleted file mode 100644
index d78d60d..0000000
--- a/src/sfml/graphics/BlendMode.zig
+++ /dev/null
@@ -1,92 +0,0 @@
-//! Blending modes for drawing (for render states)
-
-// Enums
-pub const Factor = enum(c_int) {
- zero,
- one,
- srcColor,
- oneMinusSrcColor,
- dstColor,
- oneMinusDstColor,
- srcAlpha,
- oneMinusSrcAlpha,
- dstAlpha,
- oneMinusDstAlpha
-};
-
-pub const Equation = enum(c_int) {
- add,
- subtract,
- reverseSubtract
-};
-
-const BlendMode = @This();
-
-// Preset blend modes
-pub const BlendAlpha = BlendMode{
- .color_src_factor = .srcAlpha,
- .color_dst_factor = .oneMinusSrcAlpha,
- .color_equation = .add,
- .alpha_src_factor = .one,
- .alpha_dst_factor = .oneMinusSrcAlpha,
- .alpha_equation = .add
-};
-
-pub const BlendAdd = BlendMode{
- .color_src_factor = .srcAlpha,
- .color_dst_factor = .one,
- .color_equation = .add,
- .alpha_src_factor = .one,
- .alpha_dst_factor = .one,
- .alpha_equation = .add
-};
-
-pub const BlendMultiply = BlendMode{
- .color_src_factor = .dstColor,
- .color_dst_factor = .zero,
- .color_equation = .add,
- .alpha_src_factor = .dstColor,
- .alpha_dst_factor = .zero,
- .alpha_equation = .add
-};
-
-pub const BlendMin = BlendMode{
- .color_src_factor = .one,
- .color_dst_factor = .one,
- .color_equation = .min,
- .alpha_src_factor = .one,
- .alpha_dst_factor = .one,
- .alpha_equation = .min
-};
-
-pub const BlendMax = BlendMode{
- .color_src_factor = .one,
- .color_dst_factor = .one,
- .color_equation = .max,
- .alpha_src_factor = .one,
- .alpha_dst_factor = .one,
- .alpha_equation = .max
-};
-
-pub const BlendNone = BlendMode{
- .color_src_factor = .one,
- .color_dst_factor = .zero,
- .color_equation = .add,
- .alpha_src_factor = .one,
- .alpha_dst_factor = .zero,
- .alpha_equation = .add
-};
-
-const sfBlendMode = @import("../sfml_import.zig").c.sfBlendMode;
-/// Bitcasts this blendmode to the csfml struct
-/// For inner workings
-pub fn _toCSFML(self: BlendMode) sfBlendMode {
- return @bitCast(sfBlendMode, self);
-}
-
-color_src_factor: Factor,
-color_dst_factor: Factor,
-color_equation: Equation,
-alpha_src_factor: Factor,
-alpha_dst_factor: Factor,
-alpha_equation: Equation \ No newline at end of file