Commit 322702bd authored by Samuel John Gulinello's avatar Samuel John Gulinello Committed by Rohan Kumar
Browse files

updated JSON parsing

parent b87b1c5e
Loading
Loading
Loading
Loading
+5 −5
Original line number Diff line number Diff line
@@ -97,16 +97,16 @@ async function drawPointCloud(object) {
        if (target in jsonObject || target == null) {
          
          for (let objectKey in jsonObject) {
            let object = jsonObject[objectKey];
            let object = jsonObject[objectKey]['pset'];

            // Loop through each coordinate in the object
            for (let i = 0; i < object.length; i++) {
              let coordinate = object[i];
              
              // Extract x, y, z values
              let x = coordinate[0];
              let y = coordinate[1];
              let z = coordinate[2];
              let x = coordinate['x'];
              let y = coordinate['y'];
              let z = coordinate['z'];
              let r,g,b;
              
              if(objectKey == target){