|
|
|
|
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Dear all,
I want to use the POV-RAY with LIDAR dara. The format of Lidar data could be
ascii file (txt,csv), or las/laz,all including X,Y,Z.
So do you have any recommend tools for transforming xyz data into .pov format??
Thanks a lot.
Post a reply to this message
|
|
| |
| |
|
|
From: Stephen
Subject: Re: Asking for a tool to transform .txt(x,y,z) data to POV format
Date: 24 May 2016 04:52:51
Message: <57441663$1@news.povray.org>
|
|
|
| |
| |
|
|
On 5/24/2016 9:02 AM, Mengshi wrote:
> Dear all,
>
> I want to use the POV-RAY with LIDAR dara. The format of Lidar data could be
> ascii file (txt,csv), or las/laz,all including X,Y,Z.
> So do you have any recommend tools for transforming xyz data into .pov format??
>
>
Is this a cloud of points or does it have some structure?
What is the typical file size and number of points? If you have a small
example it would help.
--
Regards
Stephen
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Stephen <mca### [at] aolcom> wrote:
> On 5/24/2016 9:02 AM, Mengshi wrote:
> > Dear all,
> >
> > I want to use the POV-RAY with LIDAR dara. The format of Lidar data could be
> > ascii file (txt,csv), or las/laz,all including X,Y,Z.
> > So do you have any recommend tools for transforming xyz data into .pov format??
> >
> >
>
> Is this a cloud of points or does it have some structure?
>
> What is the typical file size and number of points? If you have a small
> example it would help.
>
>
> --
>
> Regards
> Stephen
It just a cloud of points, about 4162388 points.
Like:
data.csv
X Y Z
35174.97656250 446497.71875000 -0.569999
35174.97656250 446497.71875000 8.0200046
35174.97656250 446497.71875000 6.2580003
.......
Post a reply to this message
|
|
| |
| |
|
|
From: Stephen
Subject: Re: Asking for a tool to transform .txt(x,y,z) data to POV format
Date: 24 May 2016 05:37:49
Message: <574420ed$1@news.povray.org>
|
|
|
| |
| |
|
|
On 5/24/2016 10:07 AM, Mengshi wrote:
> Stephen <mca### [at] aolcom> wrote:
>> On 5/24/2016 9:02 AM, Mengshi wrote:
>>> Dear all,
>>>
>>> I want to use the POV-RAY with LIDAR dara. The format of Lidar data could be
>>> ascii file (txt,csv), or las/laz,all including X,Y,Z.
>>> So do you have any recommend tools for transforming xyz data into .pov format??
>>>
>>>
>>
>> Is this a cloud of points or does it have some structure?
>>
>> What is the typical file size and number of points? If you have a small
>> example it would help.
>>
>>
>> --
>>
>> Regards
>> Stephen
>
> It just a cloud of points, about 4162388 points.
>
> Like:
> data.csv
>
> X Y Z
> 35174.97656250 446497.71875000 -0.569999
> 35174.97656250 446497.71875000 8.0200046
> 35174.97656250 446497.71875000 6.2580003
> ........
>
>
Have a look at Meshlab http://meshlab.sourceforge.net/
That should allow you to turn your point cloud into a mesh. Then you can
convert it to a povray include file with poseray.
You could also search for Point Clout and PovRay. It will return a few
threads you could read.
--
Regards
Stephen
Post a reply to this message
|
|
| |
| |
|
|
From: tth
Subject: Re: Asking for a tool to transform .txt(x,y,z) data to POV format
Date: 25 May 2016 05:00:03
Message: <57456993$1@news.povray.org>
|
|
|
| |
| |
|
|
On 05/24/2016 11:07 AM, Mengshi a dit:
>> What is the typical file size and number of points? If you have a small
>> example it would help.
>> --
>>
>> Regards
>> Stephen
>
> It just a cloud of points, about 4162388 points.
>
> Like:
> data.csv
>
> X Y Z
> 35174.97656250 446497.71875000 -0.569999
> 35174.97656250 446497.71875000 8.0200046
> 35174.97656250 446497.71875000 6.2580003
> .......
tth@serviette:/tmp$ c### [at] datacsv
X Y Z
35174.97656250 446497.71875000 -0.569999
35174.97656250 446497.71875000 8.0200046
35174.97656250 446497.71875000 6.2580003
tth@serviette:/tmp$ c### [at] scriptawk
#!/usr/bin/awk -f
BEGIN { print "union {"; }
NR!=1 {
printf "sphere { <%f, %f, %f>, DSPHERE }\n", $1, $2, $3;
}
END { print "}"; }
tth@serviette:/tmp$ ./script.awk < d### [at] acsv
union {
sphere { <35174.976562, 446497.718750, -0.569999>, DSPHERE }
sphere { <35174.976562, 446497.718750, 8.020005>, DSPHERE }
sphere { <35174.976562, 446497.718750, 6.258000>, DSPHERE }
}
--
http://weblog.mixart-myrys.org/?post/2016/03/De-la-temporalisation
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"Mengshi" <rsy### [at] gmailcom> wrote:
> Dear all,
>
> I want to use the POV-RAY with LIDAR dara. The format of Lidar data could be
> ascii file (txt,csv), or las/laz,all including X,Y,Z.
> So do you have any recommend tools for transforming xyz data into .pov format??
>
>
> Thanks a lot.
If you have access to 'sed', 'tail' and a shell (e.g. in Linux or Cygwin), you
can do this:
you@linux:~$ tail -n +2 lidar.txt | sed s/' '/', '/g | sed s/$/','/ >lidar.csv
('lidar.txt' is the file with your original lidar data.)
A file 'lidar.csv' will then be created, which can be read from a POV-Ray script
like this:
#version 3.7;
#declare NrOfPoints = 4162388;
#declare Points = array[NrOfPoints];
#fopen LidarFile "lidar.csv" read
#declare Cnt = 0;
#while (defined(LidarFile) & Cnt < NrOfPoints)
#read (LidarFile, X, Y, Z)
#declare Points[Cnt] = <X, Y, Z>;
#declare Cnt = Cnt + 1;
#end // for
#fclose LidarFile
#for (Cnt, 0, NrOfPoints-1)
#debug "\n"
#debug concat("Point no. ", str(Cnt, 0, 0), ": ")
#debug concat("<", vstr(3, Points[Cnt], ", ", 0, -1), ">")
#end // for
#debug "\n\n"
And if you have access to 'wc' you can get the number of lines in the lidar.csv
file like this:
you@linux:~$ wc --lines lidar.csv
--
Tor Olav
http://subcube.com
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
|
|