'\" -*- coding: us-ascii -*- .if \n(.g .ds T< \\FC .if \n(.g .ds T> \\F[\n[.fam]] .de URL \\$2 \(la\\$1\(ra\\$3 .. .if \n(.g .mso www.tmac .TH las2txt 1 "27 October 2016" "" "" .SH NAME las2txt \- output ASRPS LAS files into ASCII text .SH SYNOPSIS 'nh .fi .ad l \fBlas2txt\fR \kx .if (\nx>(\n(.l/2)) .nr x (\n(.l/5) 'in \n(.iu+\nxu [\fB-h\fR | \fB-i\fR \fI\fR \fB-o\fR \fI\fR \fB-t\fR \fI\fR | \fB-formats\fR] 'in \n(.iu-\nxu .ad b 'hy .SH DESCRIPTION \fBlas2txt\fR allows you to output ASRPS LAS files into ASCII text. .PP The '\*(T<\fB\-parse txyz\fR\*(T>' flag specifies how to format each line of the ASCII file. For example, '\*(T' means that the first number of each line should be the gpstime, the next three numbers should be the x, y, and z coordinate, the next number should be the intensity and the next number should be the scan angle. .PP Supported entries .TP 0.2i \(bu a - scan angle .TP 0.2i \(bu i - intensity .TP 0.2i \(bu n - number of returns for given pulse .TP 0.2i \(bu r - number of this return .TP 0.2i \(bu c - classification .TP 0.2i \(bu u - user data .TP 0.2i \(bu p - point source ID .TP 0.2i \(bu e - edge of flight line flag .TP 0.2i \(bu d - direction of scan flag .TP 0.2i \(bu R - red channel of RGB color .TP 0.2i \(bu G - green channel of RGB color .TP 0.2i \(bu B - blue channel of RGB color .TP 0.2i \(bu M - vertex index number .PP Separators .PP The '\*(T<\fB\-sep space\fR\*(T>' flag specifies what separator to use. The default is a space. The following list is valid for separator characters (case sensitive): .TP 0.2i \(bu tab .TP 0.2i \(bu comma .TP 0.2i \(bu colon .TP 0.2i \(bu hyphen .TP 0.2i \(bu dot .TP 0.2i \(bu semicolon .PP Header Separators .PP The '\*(T<\fB\-header pound\fR\*(T>' flag results in the header information being printed at the beginning of the ASCII file in form of a comment that starts with the special character '#'. Other possible special characters include (case sensitive): .TP 0.2i \(bu percent .TP 0.2i \(bu dollar .TP 0.2i \(bu semicolon .TP 0.2i \(bu comma .TP 0.2i \(bu star .TP 0.2i \(bu colon .TP 0.2i \(bu semicolon .SH OPTIONS las2txt options: .TP \*(T<\fB\-h\fR\*(T>, \*(T<\fB\-\-help\fR\*(T> produce help message .TP \*(T<\fB\-i\fR\*(T> \fIarg\fR, \*(T<\fB\-\-input\fR\*(T> \fIarg\fR input LAS file. .TP \*(T<\fB\-o\fR\*(T> \fIarg\fR, \*(T<\fB\-\-output\fR\*(T> \fIarg\fR output text file. Use 'stdout' if you want it written to the standard output stream .TP \*(T<\fB\-\-parse\fR\*(T> \fIarg\fR The '\*(T<\fB\-\-parse txyz\fR\*(T>' flag specifies how to format each line of the ASCII file. For example, '\*(T' means that the first number of each line should be the gpstime, the next three numbers should be the x, y, and z coordinate, the next number should be the intensity and the next number should be the scan angle. The supported entries are: .RS .TP 0.2i \(bu x - x coordinate as a double .TP 0.2i \(bu y - y coordinate as a double .TP 0.2i \(bu z - z coordinate as a double .TP 0.2i \(bu X - x coordinate as unscaled integer .TP 0.2i \(bu Y - y coordinate as unscaled integer .TP 0.2i \(bu Z - z coordinate as unscaled integer .TP 0.2i \(bu a - scan angle .TP 0.2i \(bu i - intensity .TP 0.2i \(bu n - number of returns for given pulse .TP 0.2i \(bu r - number of this return .TP 0.2i \(bu c - classification number .TP 0.2i \(bu C - classification name .TP 0.2i \(bu u - user data .TP 0.2i \(bu p - point source ID .TP 0.2i \(bu e - edge of flight line .TP 0.2i \(bu d - direction of scan flag .TP 0.2i \(bu R - red channel of RGB color .TP 0.2i \(bu G - green channel of RGB color .TP 0.2i \(bu B - blue channel of RGB color .TP 0.2i \(bu M - vertex index number .RE .TP \*(T<\fB\-\-precision\fR\*(T> \fIarg\fR The number of decimal places to use for x,y,z,[t] output. \*(T<\fB\-\-precision 7 7 3\fR\*(T> \*(T<\fB\-\-precision 3 3 4 6\fR\*(T> If you don't specify any precision, las2txt uses the implicit values defined by the header's scale value (and a precision of 8 is used for any time values.) .TP \*(T<\fB\-\-delimiter\fR\*(T> \fIarg\fR The character to use for delimiting fields in the output. \*(T<\fB\-\-delimiter ","\fR\*(T> \*(T<\fB\-\-delimiter ""\fR\*(T> \*(T<\fB\-\-delimiter " "\fR\*(T> .TP \*(T<\fB\-\-labels\fR\*(T> Print row of header labels .TP \*(T<\fB\-\-header\fR\*(T> Print header information .TP \*(T<\fB\-v\fR\*(T>, \*(T<\fB\-\-verbose\fR\*(T> Verbose message output .TP \*(T<\fB\-\-xml\fR\*(T> Output as XML. No formatting given by \*(T<\fB\-\-parse\fR\*(T> is respected in this case. .TP \*(T<\fB\-\-stdout\fR\*(T> Output data to stdout .PP Filtering options: .TP \*(T<\fB\-e\fR\*(T> \fIarg\fR, \*(T<\fB\-\-extent\fR\*(T> \fIarg\fR Extent window that points must fall within to keep. Use a comma-separated or quoted, space-separated list, for example, \*(T<\fB\-e minx, miny, maxx, maxy\fR\*(T> or \*(T<\fB\-e minx, miny, minz, maxx, maxy, maxz\fR\*(T> \*(T<\fB\-e "minx miny minz maxx maxy maxz"\fR\*(T> .TP \*(T<\fB\-\-minx\fR\*(T> \fIarg\fR Extent must be greater than or equal to minx to be kept. \*(T<\fB\-\-minx 1234.0\fR\*(T> .TP \*(T<\fB\-\-miny\fR\*(T> \fIarg\fR Extent must be greater than or equal to miny to be kept. \*(T<\fB\-\-miny 5678.0\fR\*(T> .TP \*(T<\fB\-\-minz\fR\*(T> \fIarg\fR Extent must be greater than or equal to minz to be kept. If maxx and maxy are set but not minz *and maxz, all z values are kept. \*(T<\fB\-\-minz 0.0\fR\*(T> .TP \*(T<\fB\-\-maxx\fR\*(T> \fIarg\fR Extent must be less than or equal to maxx to be kept. \*(T<\fB\-\-maxx 1234.0\fR\*(T> .TP \*(T<\fB\-\-maxy\fR\*(T> \fIarg\fR Extent must be less than or equal to maxy to be kept. \*(T<\fB\-\-maxy 5678.0\fR\*(T> .TP \*(T<\fB\-\-maxz\fR\*(T> \fIarg\fR Extent must be less than or equal to maxz to be kept. If maxx and maxy are set but not maxz *and minz, all z values are kept. \*(T<\fB\-\-maxz 10.0\fR\*(T> .TP \*(T<\fB\-t\fR\*(T> \fIarg\fR, \*(T<\fB\-\-thin\fR\*(T> \fIarg\fR (=0) Simple decimation-style thinning. Thin the file by removing every t'th point from the file. .TP \*(T<\fB\-\-last\-return\-only\fR\*(T> Keep last returns (cannot be used with \*(T<\fB\-\-first\-return\-only\fR\*(T>) .TP \*(T<\fB\-\-first\-return\-only\fR\*(T> Keep first returns (cannot be used with \*(T<\fB\-\-last\-return\-only\fR\*(T>) .TP \*(T<\fB\-\-keep\-returns\fR\*(T> \fIarg\fR A list of return numbers to keep in the output file: \*(T<\fB\-\-keep\-returns 1 2 3\fR\*(T> .TP \*(T<\fB\-\-drop\-returns\fR\*(T> \fIarg\fR Return numbers to drop. For example, \*(T<\fB\-\-drop\-returns 2 3 4 5\fR\*(T> .TP \*(T<\fB\-\-valid_only\fR\*(T> Keep only valid points .TP \*(T<\fB\-\-keep\-classes\fR\*(T> \fIarg\fR A list of classifications to keep: \*(T<\fB\-\-keep\-classes 2 4 12\fR\*(T> \*(T<\fB\-\-keep\-classes 2\fR\*(T> .TP \*(T<\fB\-\-drop\-classes\fR\*(T> \fIarg\fR A comma-separated list of classifications to drop: \*(T<\fB\-\-drop\-classes 1,7,8\fR\*(T> \*(T<\fB\-\-drop\-classes 2\fR\*(T> .TP \*(T<\fB\-\-keep\-intensity\fR\*(T> \fIarg\fR Range in which to keep intensity. The following expression types are supported: \*(T<\fB\-\-keep\-intensity 0\-100\fR\*(T> \*(T<\fB\-\-keep\-intensity <200\fR\*(T> \*(T<\fB\-\-keep\-intensity >400\fR\*(T> \*(T<\fB\-\-keep\-intensity >=200\fR\*(T> .TP \*(T<\fB\-\-drop\-intensity\fR\*(T> \fIarg\fR Range in which to drop intensity. The following expression types are supported: \*(T<\fB\-\-drop\-intensity <200\fR\*(T> \*(T<\fB\-\-drop\-intensity >400\fR\*(T> \*(T<\fB\-\-drop\-intensity >=200\fR\*(T> .TP \*(T<\fB\-\-keep\-time\fR\*(T> \fIarg\fR Range in which to keep time. The following expression types are supported: \*(T<\fB\-\-keep\-time 413665.2336\-414092.8462\fR\*(T> \*(T<\fB\-\-keep\-time <414094.8462\fR\*(T> \*(T<\fB\-\-keep\-time >413665.2336\fR\*(T> \*(T<\fB\-\-keep\-time >=413665.2336\fR\*(T> .TP \*(T<\fB\-\-drop\-time\fR\*(T> \fIarg\fR Range in which to drop time. The following expression types are supported: \*(T<\fB\-\-drop\-time <413666.2336\fR\*(T> \*(T<\fB\-\-drop\-time >413665.2336\fR\*(T> \*(T<\fB\-\-drop\-time >=413665.2336\fR\*(T> .TP \*(T<\fB\-\-keep\-scan\-angle\fR\*(T> \fIarg\fR Range in which to keep scan angle. The following expression types are supported: \*(T<\fB\-\-keep\-scan\-angle 0\-100\fR\*(T> \*(T<\fB\-\-keep\-scan\-angle <100\fR\*(T> \*(T<\fB\-\-keep\-scan\-angle <=100\fR\*(T> .TP \*(T<\fB\-\-drop\-scan\-angle\fR\*(T> \fIarg\fR Range in which to drop scan angle. The following expression types are supported: \*(T<\fB\-\-drop\-scan\-angle <30\fR\*(T> \*(T<\fB\-\-drop\-scan\-angle >100\fR\*(T> \*(T<\fB\-\-drop\-scan\-angle >=100\fR\*(T> .TP \*(T<\fB\-\-keep\-color\fR\*(T> \fIarg\fR Range in which to keep colors. Define colors as two 3-tuples (R,G,B-R,G,B): \*(T<\fB\-\-keep\-color '0,0,0\-125,125,125'\fR\*(T> .TP \*(T<\fB\-\-drop\-color\fR\*(T> \fIarg\fR Range in which to drop colors. Define colors as two 3-tuples (R,G,B-R,G,B): \*(T<\fB\-\-drop\-color '255,255,255\-65536,65536,65536'\fR\*(T> .PP For more information, see the full documentation for lasinfo at: \(lahttp://liblas.org/utilities/las2txt.html\(ra .SH EXAMPLE \fBSimple conversion to text file\fR .PP .nf \*(T< $ las2txt \-i lidar.las \-o lidar.txt \-parse xyz \*(T> .fi converts LAS file to ASCII and places the x, y, and z coordinate of each point at the 1st, 2nd, and 3rd entry of each line. The entries are separated by a space. \fBSpecifying a separator\fR .PP .nf \*(T< $ las2txt \-i lidar.las \-o lidar.txt \-parse txyzr \-sep komma \*(T> .fi converts LAS file to ASCII and places the gps_time as the first entry, the x, y, and z coordinates at the 2nd, 3rd, and 4th entry and the number of the return as the 5th entry of each line. The entries are separated by a komma. \fBAltering the header separator\fR .PP .nf \*(T< $ las2txt \-i lidar.las \-o lidar.txt \-parse xyzia \-sep semicolon \-header pound \*(T> .fi converts LAS file to ASCII and places the x, y, and z coordinate at the 1st, 2nd, and 3rd entry, the intensity at the 4th and the scan angle as the 5th entry of each line. The entries are separated by a semicolon. At the beginning of the file we print the header information as a comment starting with a '#' symbol. \fBAltering the coordinate order\fR .PP .nf \*(T< $ las2txt \-i lidar.las \-o lidar.txt \-parse xyzcu \-sep tab \-header percent \*(T> .fi converts LAS file to ASCII and places the x, y, and z coordinate at the 1st, 2nd, and 3rd entry, the classification at the 4th and the user data as the 5th entry of each line. The entries are separated by a semicolon. At the beginning of the file we print the header information as a comment starting with a '%' symbol.