[Bf-blender-cvs] [687410a] wiggly-widgets: New, not so chunky arrow widget drawing
Julian Eisel
noreply at git.blender.org
Tue Aug 18 00:05:04 CEST 2015
Commit: 687410a01d9d32faab86c5483d91da0a22d46e64
Author: Julian Eisel
Date: Mon Aug 17 23:41:02 2015 +0200
Branches: wiggly-widgets
https://developer.blender.org/rB687410a01d9d32faab86c5483d91da0a22d46e64
New, not so chunky arrow widget drawing
We're now using immediate drawing for arrow widgets instead of using the arrays created using the widget export script.
Although this also includes a thinner arrow generated using the export script, I decided to not use it for now, as the thin lines are drawn a bit ugly. I just #ifdef'ed it out.
===================================================================
M source/blender/windowmanager/3d_widgets/arrow_widget.c
M source/blender/windowmanager/intern/wm_generic_widgets.c
===================================================================
diff --git a/source/blender/windowmanager/3d_widgets/arrow_widget.c b/source/blender/windowmanager/3d_widgets/arrow_widget.c
index 6cd427a..b8b6286 100644
--- a/source/blender/windowmanager/3d_widgets/arrow_widget.c
+++ b/source/blender/windowmanager/3d_widgets/arrow_widget.c
@@ -1,249 +1,107 @@
-int _WIDGET_nverts_arrow = 81;
-int _WIDGET_ntris_arrow = 76;
+int _WIDGET_nverts_arrow = 25;
+int _WIDGET_ntris_arrow = 46;
float _WIDGET_verts_arrow[][3] = {
- {0.023005, 0.023005, 0.000524},
- {0.030057, 0.012450, 0.000524},
- {0.032533, 0.000000, 0.000524},
- {0.030057, -0.012450, 0.000524},
- {0.023005, -0.023005, 0.000524},
- {0.012450, -0.030057, 0.000524},
- {-0.000000, -0.032533, 0.000524},
- {-0.012450, -0.030057, 0.000524},
- {-0.023005, -0.023005, 0.000524},
- {-0.030057, -0.012450, 0.000524},
- {-0.032533, -0.000000, 0.000524},
- {-0.030057, 0.012450, 0.000524},
- {-0.023005, 0.023005, 0.000524},
- {-0.012450, 0.030057, 0.000524},
- {-0.000000, 0.032533, 0.000524},
- {0.012450, 0.030057, 0.000524},
- {-0.000000, 0.131111, 0.666568},
- {-0.050174, 0.121131, 0.666568},
- {-0.092709, 0.092709, 0.666568},
- {-0.121131, 0.050174, 0.666568},
- {-0.131111, -0.000000, 0.666568},
- {-0.121131, -0.050174, 0.666568},
- {-0.092709, -0.092709, 0.666568},
- {-0.050174, -0.121131, 0.666568},
- {-0.000000, -0.131111, 0.666568},
- {0.050174, -0.121131, 0.666568},
- {0.092709, -0.092709, 0.666568},
- {0.121131, -0.050174, 0.666568},
- {0.131111, 0.000000, 0.666568},
- {0.121131, 0.050174, 0.666568},
- {0.092709, 0.092709, 0.666568},
- {0.050174, 0.121131, 0.666568},
- {-0.000000, 0.131111, 0.666568},
- {-0.050174, 0.121131, 0.666568},
- {-0.092709, 0.092709, 0.666568},
- {-0.121131, 0.050174, 0.666568},
- {-0.131111, -0.000000, 0.666568},
- {-0.121131, -0.050174, 0.666568},
- {-0.092709, -0.092709, 0.666568},
- {-0.050174, -0.121131, 0.666568},
- {-0.000000, -0.131111, 0.666568},
- {0.050174, -0.121131, 0.666568},
- {0.092709, -0.092709, 0.666568},
- {0.121131, -0.050174, 0.666568},
- {0.131111, 0.000000, 0.666568},
- {0.121131, 0.050174, 0.666568},
- {0.092709, 0.092709, 0.666568},
- {0.050174, 0.121131, 0.666568},
- {-0.000000, -0.000000, 0.999876},
- {0.023005, 0.023005, 0.000524},
- {0.030057, 0.012450, 0.000524},
- {0.032533, 0.000000, 0.000524},
- {0.030057, -0.012450, 0.000524},
- {0.023005, -0.023005, 0.000524},
- {0.012450, -0.030057, 0.000524},
- {-0.000000, -0.032533, 0.000524},
- {-0.012450, -0.030057, 0.000524},
- {-0.023005, -0.023005, 0.000524},
- {-0.030057, -0.012450, 0.000524},
- {-0.032533, -0.000000, 0.000524},
- {-0.030057, 0.012450, 0.000524},
- {-0.023005, 0.023005, 0.000524},
- {-0.012450, 0.030057, 0.000524},
- {-0.000000, 0.032533, 0.000524},
- {0.012450, 0.030057, 0.000524},
- {0.023005, 0.023005, 0.673867},
- {0.030057, 0.012450, 0.673867},
- {0.032533, 0.000000, 0.673867},
- {0.030057, -0.012450, 0.673867},
- {0.023005, -0.023005, 0.673867},
- {0.012450, -0.030057, 0.673867},
- {-0.000000, -0.032533, 0.673867},
- {-0.012450, -0.030057, 0.673867},
- {-0.023005, -0.023005, 0.673867},
- {-0.030057, -0.012450, 0.673867},
- {-0.032533, -0.000000, 0.673867},
- {-0.030057, 0.012450, 0.673867},
- {-0.023005, 0.023005, 0.673867},
- {-0.012450, 0.030057, 0.673867},
- {-0.000000, 0.032533, 0.673867},
- {0.012450, 0.030057, 0.673867},
+ {-0.000000, 0.012320, 0.000000},
+ {-0.000000, 0.012320, 0.974306},
+ {0.008711, 0.008711, 0.000000},
+ {0.008711, 0.008711, 0.974306},
+ {0.012320, -0.000000, 0.000000},
+ {0.012320, -0.000000, 0.974306},
+ {0.008711, -0.008711, 0.000000},
+ {0.008711, -0.008711, 0.974306},
+ {-0.000000, -0.012320, 0.000000},
+ {-0.000000, -0.012320, 0.974306},
+ {-0.008711, -0.008711, 0.000000},
+ {-0.008711, -0.008711, 0.974306},
+ {-0.012320, 0.000000, 0.000000},
+ {-0.012320, 0.000000, 0.974306},
+ {-0.008711, 0.008711, 0.000000},
+ {-0.008711, 0.008711, 0.974306},
+ {0.000000, 0.072555, 0.974306},
+ {0.051304, 0.051304, 0.974306},
+ {0.072555, -0.000000, 0.974306},
+ {0.051304, -0.051304, 0.974306},
+ {-0.000000, -0.072555, 0.974306},
+ {-0.051304, -0.051304, 0.974306},
+ {-0.072555, 0.000000, 0.974306},
+ {-0.051304, 0.051304, 0.974306},
+ {0.000000, -0.000000, 1.268098},
};
float _WIDGET_normals_arrow[][3] = {
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.000000, -1.000000},
- {0.000000, 0.930570, 0.366039},
- {-0.356120, 0.859737, 0.366039},
- {-0.658010, 0.658010, 0.366039},
- {-0.859737, 0.356120, 0.366039},
- {-0.930570, 0.000000, 0.366039},
- {-0.859737, -0.356120, 0.366039},
- {-0.658010, -0.658010, 0.366039},
- {-0.356120, -0.859737, 0.366039},
- {0.000000, -0.930570, 0.366039},
- {0.356120, -0.859737, 0.366039},
- {0.658010, -0.658010, 0.366039},
- {0.859737, -0.356120, 0.366039},
- {0.930570, 0.000000, 0.366039},
- {0.859737, 0.356120, 0.366039},
- {0.658010, 0.658010, 0.366039},
- {0.356120, 0.859737, 0.366039},
+ {0.000000, 0.776360, -0.630238},
+ {0.000000, 0.594348, -0.804163},
+ {0.548967, 0.548967, -0.630238},
+ {0.420270, 0.420270, -0.804163},
+ {0.776360, 0.000000, -0.630238},
+ {0.594378, 0.000000, -0.804163},
+ {0.548967, -0.548967, -0.630238},
+ {0.420270, -0.420270, -0.804163},
+ {0.000000, -0.776360, -0.630238},
+ {0.000000, -0.594378, -0.804163},
+ {-0.548967, -0.548967, -0.630238},
+ {-0.420270, -0.420270, -0.804163},
+ {-0.776360, 0.000000, -0.630238},
+ {-0.594378, 0.000000, -0.804163},
+ {-0.548967, 0.548967, -0.630238},
+ {-0.420270, 0.420270, -0.804163},
+ {0.000000, 0.843226, -0.537492},
+ {0.596271, 0.596271, -0.537492},
+ {0.843226, 0.000000, -0.537492},
+ {0.596271, -0.596271, -0.537492},
+ {0.000000, -0.843226, -0.537492},
+ {-0.596271, -0.596271, -0.537492},
+ {-0.843226, 0.000000, -0.537492},
+ {-0.596271, 0.596271, -0.537492},
{0.000000, 0.000000, 1.000000},
- {0.707083, 0.707083, 0.000000},
- {0.923856, 0.382672, 0.000000},
- {1.000000, 0.000000, 0.000000},
- {0.923856, -0.382672, 0.000000},
- {0.707083, -0.707083, 0.000000},
- {0.382672, -0.923856, 0.000000},
- {0.000000, -1.000000, 0.000000},
- {-0.382672, -0.923856, 0.000000},
- {-0.707083, -0.707083, 0.000000},
- {-0.923856, -0.382672, 0.000000},
- {-1.000000, 0.000000, 0.000000},
- {-0.923856, 0.382672, 0.000000},
- {-0.707083, 0.707083, 0.000000},
- {-0.382672, 0.923856, 0.000000},
- {0.000000, 1.000000, 0.000000},
- {0.382672, 0.923856, 0.000000},
- {0.707083, 0.707083, 0.000000},
- {0.923856, 0.382672, 0.000000},
- {1.000000, 0.000000, 0.000000},
- {0.923856, -0.382672, 0.000000},
- {0.707083, -0.707083, 0.000000},
- {0.382672, -0.923856, 0.000000},
- {0.000000, -0.999969, 0.000000},
- {-0.382672, -0.923856, 0.000000},
- {-0.707083, -0.707083, 0.000000},
- {-0.923856, -0.382672, 0.000000},
- {-1.000000, 0.000000, 0.000000},
- {-0.923856, 0.382672, 0.000000},
- {-0.707083, 0.707083, 0.000000},
- {-0.382672, 0.923856, 0.000000},
- {0.000000, 1.000000, 0.000000},
- {0.382672, 0.923856, 0.000000},
};
unsigned short _WIDGET_indices_arrow[] = {
- 13, 1, 9,
- 49, 65, 66,
- 62, 78, 79,
- 51, 67, 68,
- 53, 69, 70,
- 55, 71, 72,
- 57, 73, 74,
- 59, 75, 76,
- 64, 80, 65,
- 61, 77, 78,
- 50, 66, 67,
- 52, 68, 69,
- 54, 70, 71,
- 56, 72, 73,
- 30, 29, 28,
- 39, 40, 48,
- 37, 38, 48,
- 35, 36, 48,
- 46, 47, 48,
- 33, 34, 48,
- 44, 45, 48,
- 42, 43, 48,
- 40, 41, 48,
- 38, 39, 48,
- 36, 37, 48,
- 47, 32, 48,
- 34, 35, 48,
- 45, 46, 48,
- 32, 33, 48,
- 43, 44, 48,
- 41, 42, 48,
- 60, 76, 77,
- 63, 79, 80,
- 58, 74, 75,
- 11, 12, 13,
- 9, 10, 11,
- 7, 8, 9,
- 7, 9, 6,
- 5, 6, 4,
- 1, 2, 3,
- 1, 14, 0,
- 63, 62, 79,
- 9, 11, 13,
- 50, 49, 66,
+ 1, 3, 2,
+ 3, 5, 4,
+ 5, 7, 6,
+ 7, 9, 8,
+ 9, 11, 10,
+ 11, 13, 12,
+ 5, 18, 19,
+ 15, 1, 0,
+ 13, 15, 14,
+ 6, 10, 14,
+ 11, 21, 22,
+ 7, 19, 20,
+ 13, 22, 23,
+ 3, 17, 18,
+ 9, 20, 21,
+ 15, 23, 16,
+ 1, 16, 17,
+ 23, 22, 24,
+ 21, 20, 24,
+ 19, 18, 24,
+ 17, 16, 24,
+ 16, 23, 24,
+ 22, 21, 24,
+ 20, 19, 24,
+ 18, 17, 24,
+ 0, 1, 2,
+ 2, 3, 4,
+ 4, 5, 6,
+ 6, 7, 8,
+ 8, 9, 10,
+ 10, 11, 12,
+ 7, 5, 19,
14, 15, 0,
- 6, 9, 1,
- 1, 13, 14,
- 6, 3, 4,
- 3, 6, 1,
- 52, 51, 68,
- 54, 53, 70,
- 56, 55, 72,
- 58, 57, 74,
- 60, 59, 76,
- 49, 64, 65,
- 62, 61, 78,
- 51, 50, 67,
- 53, 52, 69,
- 55, 54, 71,
- 57, 56, 73,
- 17, 20, 18,
- 61, 60, 77,
- 21, 20, 22,
- 23, 20, 24,
- 26, 25, 24,
- 16, 31, 30,
- 64, 63, 80,
- 28, 27, 26,
- 17, 26, 2
@@ Diff output truncated at 10240 characters. @@
More information about the Bf-blender-cvs
mailing list