[Liblas-commits] r1158 - branches/1.2/apps

liblas-commits at liblas.org liblas-commits at liblas.org
Mon Mar 30 13:59:17 EDT 2009


Author: hobu
Date: Mon Mar 30 13:59:17 2009
New Revision: 1158
URL: http://liblas.org/changeset/1158

Log:
backport r1157 to fix #121

Modified:
   branches/1.2/apps/las2txt.c
   branches/1.2/apps/txt2las.c

Modified: branches/1.2/apps/las2txt.c
==============================================================================
--- branches/1.2/apps/las2txt.c	(original)
+++ branches/1.2/apps/las2txt.c	Mon Mar 30 13:59:17 2009
@@ -544,12 +544,9 @@
             case 'M':
                 fprintf(file_out, "%d", index);
                 break;
-/*
-      case 'p': // the point source ID
-        fprintf(file_out, "%d", lasreader->point.point_source_ID);
-        break;
-*/
-   
+            case 'p':
+                fprintf(file_out, "%d", LASPoint_GetPointSourceId(p));
+                break;
             /* the edge of flight line flag */
             case 'e': 
                 fprintf(file_out, "%d", LASPoint_GetFlightLineEdge(p));

Modified: branches/1.2/apps/txt2las.c
==============================================================================
--- branches/1.2/apps/txt2las.c	(original)
+++ branches/1.2/apps/txt2las.c	Mon Mar 30 13:59:17 2009
@@ -253,6 +253,7 @@
                         "WARNING: point source ID %d is out of range of unsigned short\n", 
                         temp_i);
 /*          point->point_source_ID = temp_i & 65535; */
+            LASPoint_SetPointSourceId(point, temp_i & 65535);
             /*// then advance to next white space */
             while (l[0] && l[0] != ' ' && l[0] != ',' && l[0] != '\t') l++; 
         }


More information about the Liblas-commits mailing list