Browse code

see Changelog in documentation folder

lorglas authored onWed/Jul/2020 05:0:th • Lorenz Glaser committed onMon/Aug/2020 12:0:th
Showing0 changed files
Browse code

cleanup repo, spinner and makefile error

lorglas authored onWed/Feb/2020 22:0:th • GitHub committed onWed/Feb/2020 22:0:th
Showing1 changed files
1 1
new file mode 100644
... ...
@@ -0,0 +1,107 @@
1
+/*
2
+Open Tracker License
3
+
4
+Terms and Conditions
5
+
6
+Copyright (c) 1991-2000, Be Incorporated. All rights reserved.
7
+
8
+Permission is hereby granted, free of charge, to any person obtaining a copy of
9
+this software and associated documentation files (the "Software"), to deal in
10
+the Software without restriction, including without limitation the rights to
11
+use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
12
+of the Software, and to permit persons to whom the Software is furnished to do
13
+so, subject to the following conditions:
14
+
15
+The above copyright notice and this permission notice applies to all licensees
16
+and shall be included in all copies or substantial portions of the Software.
17
+
18
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
19
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF TITLE, MERCHANTABILITY,
20
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
21
+BE INCORPORATED BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
22
+AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF, OR IN CONNECTION
23
+WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
24
+
25
+Except as contained in this notice, the name of Be Incorporated shall not be
26
+used in advertising or otherwise to promote the sale, use or other dealings in
27
+this Software without prior written authorization from Be Incorporated.
28
+
29
+Tracker(TM), Be(R), BeOS(R), and BeIA(TM) are trademarks or registered trademarks
30
+of Be Incorporated in the United States and other countries. Other brand product
31
+names are registered trademarks or trademarks of their respective holders.
32
+All rights reserved.
33
+*/
34
+
35
+/*******************************************************************************
36
+/
37
+/	File:			ColorTools.h
38
+/
39
+/   Description:    Additional experimental color manipulation functions.
40
+/
41
+/	Copyright 2000, Be Incorporated, All Rights Reserved
42
+/
43
+*******************************************************************************/
44
+
45
+
46
+#ifndef _COLOR_TOOLS_H
47
+#define _COLOR_TOOLS_H
48
+
49
+#include <GraphicsDefs.h>
50
+
51
+#if B_BEOS_VERSION <= B_BEOS_VERSION_MAUI
52
+
53
+namespace BExperimental {
54
+
55
+// Comparison operators.
56
+
57
+inline bool operator==(const rgb_color c1, const rgb_color c2)
58
+{
59
+	return (*((uint32*)&c1)) == (*((uint32*)&c2));
60
+}
61
+
62
+inline bool operator!=(const rgb_color c1, const rgb_color c2)
63
+{
64
+	return (*((uint32*)&c1)) != (*((uint32*)&c2));
65
+}
66
+
67
+// Color creation.
68
+
69
+#ifndef HAIKU
70
+
71
+inline rgb_color make_color(uint8 red, uint8 green, uint8 blue, uint8 alpha=255)
72
+{
73
+	rgb_color c;
74
+	c.red = red;
75
+	c.green = green;
76
+	c.blue = blue;
77
+	c.alpha = alpha;
78
+	return c;
79
+}
80
+
81
+#endif
82
+
83
+// Mix two colors together, ignoring their relative alpha channels.
84
+// If amount is 0, the result is color1; if 255, the result is color2;
85
+// if another value, it is somewhere in-between.  The resulting alpha
86
+// channel is mixed exactly like the other color channels.
87
+//rgb_color mix_color(rgb_color color1, rgb_color color2, uint8 amount);
88
+
89
+// Blend two colors together, weighting by their relative alpha channels.
90
+// The resulting color is the same as mix_color(), except that the amount
91
+// used from color1 and color2's color channels is dependent on that color's
92
+// alpha channel.  For example, if color1.alpha is 0 and color2.alpha is
93
+// 255, the resulting red, green, and blue values will be the same as those
94
+// in color2, regardless of 'amount'.
95
+rgb_color blend_color(rgb_color color1, rgb_color color2, uint8 amount);
96
+
97
+// Return a color that is the disabled representation of 'color' when drawn
98
+// on a solid color 'background'.
99
+rgb_color disable_color(rgb_color color, rgb_color background);
100
+
101
+}	// namespace BExperimental
102
+
103
+using namespace BExperimental;
104
+
105
+#endif
106
+
107
+#endif