Commit 9c10c5892e26a33420d88945d411b0cc0823604d

Authored by Amrita Vishnoi
1 parent 6b4aa0ed

modification

400-SOURCECODE/AIAHTML5.Web/term-number-wp.js
... ... @@ -3,7 +3,6 @@ var doneBRID = [];
3 3 var abc = 'hello';
4 4  
5 5 getLocationForMatchedTermsInWholeBody = function (termList, maskCanvasData, coloredImageCanvasList, coloredImageMRCanvasList, grayImageDataList, grayImageMRDataList) {
6   - // console.log('for termNumer: ' + termNo + ', time: ' + new Date().toTimeString().replace(/.*(\d{2}:\d{2}:\d{2}).*/, "$1"))
7 6 var matchedRGBLocationInBodyRegion = [];
8 7 var matched;
9 8  
... ... @@ -11,7 +10,6 @@ getLocationForMatchedTermsInWholeBody = function (termList, maskCanvasData, colo
11 10 {
12 11  
13 12 matched = false;
14   - // alert('called for bodyRegionId: ' + $scope.MaskImageSRC[x].bodyRegionId);
15 13 var bodyRegionId = maskCanvasData[x].bodyRegionId;
16 14 var canvasId = maskCanvasData[x].canvasId;
17 15 var maskData = maskCanvasData[x].maskData;
... ... @@ -19,15 +17,7 @@ getLocationForMatchedTermsInWholeBody = function (termList, maskCanvasData, colo
19 17 var coloredImageDataVar= coloredImageCanvasList[bodyRegionId - 1];
20 18 var grayImageDataVar = grayImageDataList[bodyRegionId - 1];
21 19  
22   - //if (canvasId.match('MR')) {
23   - // coloredImageDataVar = coloredImageMRCanvasList[bodyRegionId - 1];
24   - // grayImageDataVar = grayImageMRDataList[bodyRegionId - 1];
25   - //}
26   - //else {
27   - // coloredImageDataVar = coloredImageCanvasList[bodyRegionId - 1];
28   - // grayImageDataVar = grayImageDataList[bodyRegionId - 1];
29   - //}
30   -
  20 +
31 21 var counter = 0;
32 22  
33 23 var imageDataVar = maskData.data;
... ... @@ -47,30 +37,18 @@ getLocationForMatchedTermsInWholeBody = function (termList, maskCanvasData, colo
47 37 });
48 38  
49 39 machLocationWP.onmessage = function (e) {
50   - console.log('callback: ' + e.data.value+', x='+x);
51   -
52   - //var upadteddata = e.data.value;
53   - //var bodyRegionId = e.data.bodyRegionId;
54   -
55   - //var grayCanvasID = 'imageCanvas' + bodyRegionId;
56   - //var grayCanvas = document.getElementById(grayCanvasID);
57   - //var grayCanvasContext = grayCanvas.getContext("2d");
58   -
  40 +
59 41  
60 42  
61   - //grayCanvasContext.putImageData(upadteddata, 0, 0);
62 43 doneBRID.push(e.data.bodyRegionId);
63 44 UpdatedGrayImageDataList[e.data.bodyRegionId] = e.data.value
64   -
65   - console.log('UpdatedGrayImageDataList: '+ UpdatedGrayImageDataList);
66   -
67   - console.log('doneBRID: ' + e.data.bodyRegionId+'length: '+doneBRID.length);
  45 +
68 46  
69 47 if (doneBRID.length==9) {
70   - console.log('before sending UpdatedGrayImageDataList= ' + UpdatedGrayImageDataList)
  48 +
71 49 self.postMessage({
72 50 'value': UpdatedGrayImageDataList,
73   - 'name': 'Happy'
  51 +
74 52 })
75 53 }
76 54  
... ...