NLeSC/ahn-pointcloud-viewer

View on GitHub

Showing 65 of 154 total issues

Function PointcloudExtractionSelectionService has 88 lines of code (exceeds 25 allowed). Consider refactoring.
Open

  function PointcloudExtractionSelectionService(THREE, SceneService, ExtractionSelectionService, ExtractionDrawingService, Messagebus, Potree) {
    var me = this;

    this.selectionActive = false;
    this.mouseDownPoint = null;
Severity: Major
Found in app/scripts/extract/pointcloud.extraction.selection.service.js - About 3 hrs to fix

    Function BigLegendController has 87 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

      function BigLegendController($scope, DecimalAdjust, Messagebus, UserAgent, PointcloudService) {
        this.PointcloudService = PointcloudService;
    
        this.mobile = UserAgent.mobile;
    
    
    Severity: Major
    Found in app/scripts/biglegend/biglegend.controller.js - About 3 hrs to fix

      Function ExtractionSelectionService has 79 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

        function ExtractionSelectionService(Messagebus, debounce) {
          this._active = false;
      
          this._left = 93720.22;
          this._bottom = 436899.97;
      Severity: Major
      Found in app/scripts/extract/extraction.selection.service.js - About 3 hrs to fix

        Function ExtractionDrawingService has 79 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

          function ExtractionDrawingService(THREE, SceneService, Messagebus) {
            this.color = new THREE.Color(0xffffff);
        
            this.renderer = null;
            this.scene = null;
        Severity: Major
        Found in app/scripts/extract/pointcloud.extraction.drawing.service.js - About 3 hrs to fix

          Function render has 75 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

                this.render = function(renderer) {
          
                  var width = me.elRenderArea.clientWidth;
                  var height = me.elRenderArea.clientHeight;
          
          
          Severity: Major
          Found in app/scripts/pointcloud/pointcloud.service.js - About 3 hrs to fix

            Function update2DFrustum has 73 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                this.update2DFrustum = function() {
                  rightBottomCorner = rightBottomCorner.set(1, -1, 1).unproject(this.camera).normalize();
                  leftBottomCorner = leftBottomCorner.set(-1, -1, 1).unproject(this.camera).normalize();
            
                  leftTopCorner = leftTopCorner.set(-1, 1, 1).unproject(this.camera).normalize();
            Severity: Major
            Found in app/scripts/pointcloud/camera.service.js - About 2 hrs to fix

              Function update has 63 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  this.update = function(){
                  var i, point, msg;
              
                      if (this.points.length === 0){
                          return;
              Severity: Major
              Found in app/scripts/utils/MeasuringTool.js - About 2 hrs to fix

                Function render has 54 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                      this.render = function() {
                        initEDL();
                
                        resize();
                
                
                Severity: Major
                Found in app/scripts/pointcloud/pointcloud.service.js - About 2 hrs to fix

                  Function PointcloudService has 17 arguments (exceeds 4 allowed). Consider refactoring.
                  Open

                    function PointcloudService(THREE, Potree, $window, $rootScope, $location,
                      DrivemapService,
                      CameraService, SceneService,
                      PathControls, MeasuringService, EarthcontrolsService,
                      RailService, ExtractionDrawingService, PointcloudExtractionSelectionService,
                  Severity: Major
                  Found in app/scripts/pointcloud/pointcloud.service.js - About 2 hrs to fix

                    Function SearchPanelController has 53 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                      function SearchPanelController(BingGeoCoderService, SceneService, PathControls, Messagebus, $window, toastr, THREE, proj4) {
                        this.query = '';
                        this.hasGeoLocation = 'geolocation' in $window.navigator;
                    
                        this.clear = function() {
                    Severity: Major
                    Found in app/scripts/searchbox/searchbox.controller.js - About 2 hrs to fix

                      Function EarthcontrolsService has 50 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                        function EarthcontrolsService($rootScope, $location, Messagebus, THREE, PathControls, RailService) { // jshint ignore:line
                          this.enabled = true;
                      
                          this.earthControls = null;
                          this.pathcontrols = PathControls;
                      Severity: Minor
                      Found in app/scripts/earthcontrols/earthcontrols.service.js - About 2 hrs to fix

                        Function CamFrustumService has 48 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                          function CamFrustumService(ol, THREE) {
                            this.camFrustum = new ol.geom.LineString([[0, 0], [1, 0], [0, 1]]);
                            var featureVector = new ol.source.Vector({
                              features: [new ol.Feature(this.camFrustum)]
                            });
                        Severity: Minor
                        Found in app/scripts/minimap/cam-frustum.service.js - About 1 hr to fix

                          Function ExtractionController has 47 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                            function ExtractionController(ExtractionSelectionService, pattyConf, Messagebus, $http, toastr) {
                              this.selection = ExtractionSelectionService;
                              this.email = '';
                              this.size = {
                                coverage: 1,
                          Severity: Minor
                          Found in app/scripts/extract/extraction.controller.js - About 1 hr to fix

                            Function addMarker has 46 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                                this.addMarker = function(point){
                                    this.points.push(point);
                            
                                    // sphere
                                    var sphere = new THREE.Mesh(sphereGeometry, createSphereMaterial());
                            Severity: Minor
                            Found in app/scripts/utils/MeasuringTool.js - About 1 hr to fix

                              Function loadPointcloud has 43 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                                  this.loadPointcloud = function() {
                                    // load pointcloud
                                    var pointcloudPath = DrivemapService.getPointcloudUrl();
                                    me.stats.lasCoordinates.crs = DrivemapService.getCrs();
                              
                              
                              Severity: Minor
                              Found in app/scripts/pointcloud/pointcloud.service.js - About 1 hr to fix

                                Function initHQSPlats has 42 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                      var initHQSPlats = function() {
                                        if (depthMaterial !== null) {
                                          return;
                                        }
                                
                                
                                Severity: Minor
                                Found in app/scripts/pointcloud/pointcloud.service.js - About 1 hr to fix

                                  Function update has 42 lines of code (exceeds 25 allowed). Consider refactoring.
                                  Open

                                      this.update = function() {
                                        Potree.pointLoadLimit =  me.settings.pointCountTarget * 2 * 1000 * 1000;
                                  
                                        if (me.settings.useEDL) {
                                          directionalLight.position.copy(camera.position);
                                  Severity: Minor
                                  Found in app/scripts/pointcloud/pointcloud.service.js - About 1 hr to fix

                                    Function HelpModalController has 39 lines of code (exceeds 25 allowed). Consider refactoring.
                                    Open

                                      function HelpModalController($window, UserAgent) {
                                        this.mobile = UserAgent.mobile;
                                        this.doNotShow = false;
                                    
                                        this.dontShowClicked = function() {
                                    Severity: Minor
                                    Found in app/scripts/helpModal/helpModal.controller.js - About 1 hr to fix

                                      Function SettingsController has 38 lines of code (exceeds 25 allowed). Consider refactoring.
                                      Open

                                        function SettingsController(PointcloudService, MeasuringService, Messagebus, PathControls, RailService) {
                                          this.showSettings = false;
                                          // this.predefinedSettings = PointcloudService.predefinedSettings;
                                          // this.settings = PointcloudService.settings;
                                          this.PointcloudService = PointcloudService;
                                      Severity: Minor
                                      Found in app/scripts/settings/settings.controller.js - About 1 hr to fix

                                        Function update has 37 lines of code (exceeds 25 allowed). Consider refactoring.
                                        Open

                                            this.update = function(){
                                            var measurements = [], pr, distance, scale, i, j, label;
                                        
                                                for(i = 0; i < this.measurements.length; i++){
                                                    measurements.push(this.measurements[i]);
                                        Severity: Minor
                                        Found in app/scripts/utils/MeasuringTool.js - About 1 hr to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language