1
2
3
4 package de.desy.acop.video;
5
6 import java.awt.Color;
7
8 import de.desy.tine.types.IMAGE;
9
10
11
12
13
14
15
16
17
18 public class Definitions {
19
20
21
22
23 public static final int MAX_WIDTH = 2000;
24 public static final int MAX_HEIGHT = 2000;
25 public static final int IMAGE_SIZE = IMAGE.HEADER_SIZE + 8;
26
27
28
29
30
31 public static final int A_IMAGE_MAX_SIZE = IMAGE_SIZE + 10*4 + 22*8 + 2 + 8*MAX_HEIGHT + 8*MAX_WIDTH;
32
33
34 private static final Color BACKGROUND_COLOR = Color.DARK_GRAY;
35 private static final Color CANVAS_COLOR = Color.BLACK;
36 private static final Color NEGATIVE_CANVAS_COLOR = Color.WHITE;
37 private static final Color ROI_COLOR = Color.BLUE;
38 private static final Color ROI_SELECTING_COLOR = Color.YELLOW;
39 private static final Color NEGATIVE_ROI_SELECTING_COLOR = Color.GREEN;
40 private static final Color DATA_COLOR = Color.WHITE;
41 private static final Color NEGATIVE_DATA_COLOR = Color.BLACK;
42 private static final Color FIT_COLOR = Color.GREEN;
43 private static final Color STATISTICS_COLOR = Color.RED;
44 private static final Color THRESHOLD_ROI_COLOR = Color.ORANGE;
45
46 private static final boolean negatives = true;
47
48 public static Color getBackgroundColor() {
49 return BACKGROUND_COLOR;
50 }
51
52 public static Color getCanvasColor() {
53 if (negatives) return NEGATIVE_CANVAS_COLOR;
54 return CANVAS_COLOR;
55 }
56
57
58
59
60
61
62 public static Color getRoiColor() {
63 return ROI_COLOR;
64 }
65
66
67
68
69
70
71 public static Color getThresholdRoiColor() {
72 return THRESHOLD_ROI_COLOR;
73 }
74
75 public static Color getRoiSelectingColor() {
76 if (negatives) return NEGATIVE_ROI_SELECTING_COLOR;
77 return ROI_SELECTING_COLOR;
78 }
79
80 public static Color getDataColor() {
81 if (negatives) return NEGATIVE_DATA_COLOR;
82 return DATA_COLOR;
83 }
84
85
86
87
88
89
90 public static Color getFitColor() {
91 return FIT_COLOR;
92 }
93
94
95
96
97
98 public static Color getStatisticsColor() {
99 return STATISTICS_COLOR;
100 }
101 }