- for (int j: channel.objectIndices) {
- if (j > 0) {
- Cube cube = _model.getCubeByRawIndex(j);
- for (LXPoint p : cube.points) {
- int c = (p.index < 0) ? 0 : colors[p.index];
+ for (int rawCubeIndex : channel.objectIndices) {
+ if (rawCubeIndex > 0) {
+ Cube cube = _model.getCubeByRawIndex(rawCubeIndex);
+
+ // TODO(mcslee): clean this up, precompute paths
+ for (int stripIndex : GRIZZLY_STRIP_ORDERING) {
+ Strip strip = cube.strips.get(stripIndex);
+ int stripLen = ((stripIndex == 9) || (stripIndex == 16)) ? 15 : 16;
+ for (int i = stripLen-1; i >= 0; --i) {
+ int c = colors[strip.points.get(i).index];