Skip to content

Commit

Permalink
Fix point_color_mode value to be uppercase
Browse files Browse the repository at this point in the history
  • Loading branch information
twojtasz committed Dec 9, 2019
1 parent dabb4a5 commit 6eaf43f
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
2 changes: 1 addition & 1 deletion examples/get-started/src/constants.js
Expand Up @@ -50,5 +50,5 @@ export const APP_SETTINGS = {

export const XVIZ_STYLE = {
'/tracklets/objects': [{name: 'selected', style: {fill_color: '#ff8000aa'}}],
'/lidar/points': [{style: {point_color_mode: 'elevation'}}]
'/lidar/points': [{style: {point_color_mode: 'ELEVATION'}}]
};
2 changes: 1 addition & 1 deletion examples/xviz-playground/src/code-samples.js
Expand Up @@ -54,7 +54,7 @@ const streamMetadata = {
.type('POINTS')
.coordinate('VEHICLE_RELATIVE')
.streamStyle({
point_color_mode: 'elevation',
point_color_mode: 'ELEVATION',
point_color_domain: [0, 3],
radius_pixels: 4
})
Expand Down
Expand Up @@ -22,11 +22,15 @@ import {PointCloudLayer as CorePointCloudLayer} from '@deck.gl/layers';

import vs from './point-cloud-layer-vertex.glsl';

// Both cases are for backwards compatibility
/* eslint-disable camelcase */
const COLOR_MODE = {
default: 0,
elevation: 1,
distance_to_vehicle: 2
distance_to_vehicle: 2,
DEFAULT: 0,
ELEVATION: 1,
DISTANCE_TO_VEHICLE: 2
};

const COLOR_DOMAIN = {
Expand Down
2 changes: 1 addition & 1 deletion test/apps/viewer/src/constants.js
Expand Up @@ -54,7 +54,7 @@ export const APP_SETTINGS = {

export const XVIZ_STYLE = {
'/tracklets/objects': [{name: 'selected', style: {fill_color: '#ff8000aa'}}],
'/lidar/points': [{style: {point_color_mode: 'elevation'}}]
'/lidar/points': [{style: {point_color_mode: 'ELEVATION'}}]
};

export const STYLES = {
Expand Down

0 comments on commit 6eaf43f

Please sign in to comment.