potree / cpotree Goto Github PK
View Code? Open in Web Editor NEWPotree Utilities
License: Other
Potree Utilities
License: Other
Hi,
I couldn't find among the writer classes anyone which extracts and saves the normals.
Since I wrote my own custom writer for ply format (inspired by those already in include folder), I was wondering how to convert the extracted normals to floats?
I know each of nx
, ny
, nz
is stored as an int16
as mentioned in the metadata, but should I use the same scale and offset as for xyz positions to turn them into space world?
This is what I did but I think I should be using another scale,offset pair for normals (as the normals weren't in the right direction always in meshlab):
auto buff_nx = points->attributeBuffersMap["nx"];
auto buff_ny = points->attributeBuffersMap["ny"];
auto buff_nz = points->attributeBuffersMap["nz"];
// save normal of point to vector
int16_t NX, NY, NZ;
memcpy(&NX, buff_nx->data_u8 + i_point * 2, 2);
memcpy(&NY, buff_ny->data_u8 + i_point * 2, 2);
memcpy(&NZ, buff_nz->data_u8 + i_point * 2, 2);
double nx = double(NX) * scale.x + offset.x;
double ny = double(NY) * scale.y + offset.y;
double nz = double(NZ) * scale.z + offset.z;
// normals.push_back({ nx, ny, nz });
normals.push_back({ static_cast<float>(nx), static_cast<float>(ny), static_cast<float>(nz) });
Some octree nodes report a byteSize of 0 but numPoints larger than 0. This was causing crashes, now these nodes are ignored, instead:
Line 336 in eddc946
Why is this happening, though? Is the hierarchy description wrong? Is octree.bin actually missing point data? Is CPotree incorrectly parsing the hierarchy?
Initially, CPotree should output the same data as previously.
This is how CPotree is currently in use:
Hi Markus,
I am unable to run CPotree after having installed the Intel TBB library (libtbb-dev
) along with the standard C++ library in its latest version (libstdc++-8-dev
) in Debian Buster (Dockerized).
Here is the command and the error message that I got:
root@01234:/app# extract_profile data/2525_1185.las -o output/ --coordinates "{2525800,2011700},{2525900,2011800}" --width 10 --min-level 0 --max-level 5
Error is as follow:
extract_profile: /usr/lib/x86_64-linux-gnu/libstdc++.so.6: version `GLIBCXX_3.4.26' not found (required by extract_profile)
After exploring libstdc++.so.6
, I've seen that GLIBCXX_3.4.26
is not there:
root@01234:/app# strings /usr/lib/x86_64-linux-gnu/libstdc++.so.6 | grep GLIBCXX
GLIBCXX_3.4
GLIBCXX_3.4.1
GLIBCXX_3.4.2
GLIBCXX_3.4.3
GLIBCXX_3.4.4
GLIBCXX_3.4.5
GLIBCXX_3.4.6
GLIBCXX_3.4.7
GLIBCXX_3.4.8
GLIBCXX_3.4.9
GLIBCXX_3.4.10
GLIBCXX_3.4.11
GLIBCXX_3.4.12
GLIBCXX_3.4.13
GLIBCXX_3.4.14
GLIBCXX_3.4.15
GLIBCXX_3.4.16
GLIBCXX_3.4.17
GLIBCXX_3.4.18
GLIBCXX_3.4.19
GLIBCXX_3.4.20
GLIBCXX_3.4.21
GLIBCXX_3.4.22
GLIBCXX_3.4.23
GLIBCXX_3.4.24
GLIBCXX_3.4.25
GLIBCXX_DEBUG_MESSAGE_LENGTH
Any hint on that? Do you rely on precompiled C++ standard lib?
Would it be possible to rely on the latest GLIBCXX_3.4.25
available in libstdc++.so.6
?
Thanks a lot!
Best Regards.
When I use the extract_profile tool, it appears that the points extracted to the .las file do not have the GpsTime data that is in the original pointcloud.
Is it a bug or do I need to pass a parameter?
I run the tool as follows:
./extract_profile.exe "E:\PointClouds\Track_A" -o "E:\tmp\retz.laz" --coordinates "{564615.531, 4405035.518, 189.464},{564663.891, 4405027.402, 189.343}" --width 50 --min-level 0 --max-level 12
and the metadata.json file: metadata.json
Hi! Does this tool support CORS url inputs?
The filesystem mounted version works fine for me:
extract_profile.exe Y:/pointclouds/bathy -o D:/bathymetry.laz --coordinates "{1,2},{2,4}" --width 5
But trying to point it at the url doesn't
extract_profile.exe https://pointcloud.ucsd.edu/pointclouds/bathy -o D:/bathymetry.laz --coordinates "{1,2},{2,4}" --width 5
Am I just missing some way to specify that it's a URL?
Thanks very much!
Hello,
I'm trying to get the list of all the points with their position, color and intensity of a potree project (already converted). To do that, I have added a getColor and getIntensity on the Points class in order to read the rgb and intensity attribute buffer. The problem is that the values returned aren't colors and intensity. Do you have any solution ?
Here is my code :
dvec3 getColor(int64_t i)
{
shared_ptr<Buffer>& buffer = attributeBuffersMap["rgb"];
int32_t R, G, B;
memcpy(&R, buffer -> data_u8 + i * 6 + 0, 2);
memcpy(&G, buffer -> data_u8 + i * 6 + 2, 2);
memcpy(&B, buffer -> data_u8 + i * 6 + 4, 2);
return {R, G, B};
}
int64_t getIntensity(int64_t i)
{
shared_ptr<Buffer>& buffer = attributeBuffersMap["intensity"];
int64_t I;
memcpy(&I, buffer -> data_u8 + i * 2, 2);
return I;
}
Thank you in advance
Maybe that one too should be public, right ?
Can you provide examples of "extract_area"?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.