liangliangnan / easy3d Goto Github PK
View Code? Open in Web Editor NEWA lightweight, easy-to-use, and efficient C++ library for processing and rendering 3D data
License: GNU General Public License v3.0
A lightweight, easy-to-use, and efficient C++ library for processing and rendering 3D data
License: GNU General Public License v3.0
For now several libraries builds in easy3d: algo, core, fileio, kdtree, util, renderer, gui, viewer. As a result corresponding binary items are being created like libalgo.a, libcore.a, ...
But such namings are not suitable for adding easy3d libraries in separate projects for several reasons:
So probably adding prefix easy3d to artifact names will be a better style: easy3d_core, easy3d_gui, ...
Is this possible to visualize octree data structure in Easy3d?. Because I am trying to insert my octree files, but it is showing in the compiler window that octree is working and it is not replicate in visualization window.
Hi,
So far I did octree, frustum culling and level of detail in this library. When I tried to load more than 2.5 million points, it kick me out from the debugging. Is this possible to handle large amount pointclouds in this library. Can you please give some suggestions?
I'm trying to display lines on Qt. My problem is that nothing is displayed if I add LinesDrawable to a mesh (or a pointcloud). Here is a reproducible code (diff for Tutorial_303_Viewer_Qt).
If I build and run it in Debug, I see the following error messages.
debug : High - API - ERROR : GL_INVALID_OPERATION error generated. VAO names must be generated with glGenVertexArrays before they can be bound or used.
GL error:
file: vertex_array_object.cpp
line: 83
function: bind
info: Invalid operation (The specified operation is not allowed in the current state)
debug : High - API - ERROR : GL_INVALID_OPERATION error generated. Array object is not active.
GL error:
file: drawable.cpp
line: 275
function: draw
info: Invalid operation (The specified operation is not allowed in the current state)
Adding glGenVertexArrays() call didn't solve the problem.
My environment is Ubuntu 18.04 x64 with Geforce 1080.
i was set cam->upAxis bur model cant change upAxis.
(edit found solution, described in comments below)
Hello,
Thank you for creating this incredible tool, it has been very useful on my other computer.
I am on a new laptop running into a problem with the shaders as seen in the screenshots attached. I did not have this issue on my desktop. GPU is RTX 2080 on desktop. Laptop has RTX 2080 super max-q).
The Viewer does not render things that use the shaders such as point impostor spheres which is my primary goal. The console is rapidly spammed when the mouse is moved in the Viewer window. I am able to workaround by just adding the PointsDrawable to the Viewer and not setting impostor type.
I was not able to solve this problem with googling. I hope you have some insight into this.
Here is the console output for your Copy/Paste convenience:
2021-02-25` 18:29:58,702 ERROR [default] Type mismatch: Type of gl_ClipDistance different between shaders.
Out of resource error.
- 'points/points_spheres_geometry_color'
debug : High - SHADER COMP - ERROR : SHADER_ID_LINK error has been generated. GLSL link failed for program 8, "": Type mismatch: Type of gl_ClipDistance different between shaders.
Out of resource error.
Pictures are just samples, I can provide more if you wish.
Thank you even if this cannot be solved!
This last picture is from my code trying to set imposter type to PointsDrawable::SPHERE. Just commenting out "drawable->set_impostor_type(PointsDrawable::SPHERE);" will make there be no issues - probably because the shader isn't being used.
if possible, implement recognize 3d model on images through rotation matrix.
thanks.
hi,
Transparency can possible without fbo? (Tutorial_505_Transparency)
thanks.
hi,
you have any tutorial for texture quads from image?
texture draw as background.
jignesh
Hello,
I would like to integrate your viewer to show a live point cloud stream in a wider application.
I have a few doubts:
debug : High - API - ERROR : GL_INVALID_OPERATION error generated. Buffer name does not refer to an buffer object generated by OpenGL.
debug : High - API - ERROR : GL_INVALID_OPERATION error generated. Target buffer must be bound and not overlapped with mapping range.
debug : High - API - ERROR : GL_INVALID_OPERATION error generated. Buffer name does not refer to an buffer object generated by OpenGL.
debug : High - API - ERROR : GL_INVALID_OPERATION error generated. Target buffer must be bound and not overlapped with mapping range.
debug : High - API - ERROR : GL_INVALID_OPERATION error generated. Buffer name does not refer to an buffer object generated by OpenGL.
debug : High - API - ERROR : GL_INVALID_OPERATION error generated. Target buffer must be bound and not overlapped with mapping range.
E0612 19:56:27.232616 8642 vertex_array_object.cpp:79] GL error:
file: /media/xxx/Data/Libraries/Easy3D/easy3d/renderer/vertex_array_object.cpp
line: 79
function: bind
info: Invalid operation (The specified operation is not allowed in the current state)
I'm not really able to undestand it. May you help me, please?
Thank you very much and congratulations for your great work!
Hello,
At first thanks a lot for the library.
I really need what this library supports in my qt application. In particular, i would like to call the methods of this lib inside my qt application. However, i did not understand how i could this.
I would like to point out that i use cmake outside qt to configure the source code.
Could you please help me?
Thank you in advance,
Elena.
I'm trying to use Easy3D from my own package, but I can't really understand how I'm supposed to get the 3rd party libraries right to make it compile. I'm getting this error:
Cannot open include file: '3rd_party/glog/glog/logging.h': No such file or directory
But in LiangliangNan\Easy3D\3rd_party\glog
there is no glog
directory, so I don't understand how the code compiles in the examples. Can you explain? I added LiangliangNan/Easy3D/3rd_party
to the include path in my CMakeLists.txt file but it's not found (because the glog directory doesn't contain a glog subdirectory).
What am I doing wrong?
Hi,
Is there a way to
Thanks
implement Rotate model Only X axis and only Y axis method.
surface mesh vertices transform from rotation matrix method.
thanks.
I was trying to visualize the bunny.bin example using the code you provided in Quick glance section but the bunny is showed in green only. Could you please suggest what could have been wrong? I am using Windows OS. --Thanks!
hi Liangliang
VS2017 编译有错误:
严重性 代码 说明 项目 文件 行 禁止显示状态
错误 C2666 “easy3d::Vec<4,float>::operator []”: 2 个重载有相似的转换 easy3d (Easy3D\easy3d) C:\Users\Jiaquan\Desktop\Easy3D-v_1.0\easy3d\transform.cpp 208
Hi,
This library is super useful for easy and simple visualization but it must be integrated into other projects in order to serve it purpose. Integrating a cmake project into another one is little cumbersome while a deb package containing lib files is easier :)
I have a box.obj file, but the box does not have a normal vector, so in the viewer there is no 3D lighting.
box.obj------------------------------------------------
v -48.000000 -48.000000 -48.000000
v 48.000000 -48.000000 -48.000000
v 48.000000 48.000000 -48.000000
v -48.000000 48.000000 -48.000000
v -48.000000 48.000000 48.000000
v 48.000000 48.000000 48.000000
v 48.000000 -48.000000 48.000000
v -48.000000 -48.000000 48.000000
f 1 2 3
f 1 3 4
f 5 4 3
f 5 3 6
f 6 3 2
f 6 2 7
f 7 2 1
f 7 1 8
f 8 1 4
f 8 4 5
f 8 5 6
f 8 6 7
Provide Python bindings for Easy3D
At line 72 (and other lines below), the following is hardcoded which doesn't run on 32-bit Windows:
#ifdef _MSC_VER
#include <intrin.h>
#pragma intrinsic(_BitScanForward64)
#pragma intrinsic(_BitScanReverse64)
#endif
A workaround is to replace the above code by
#ifdef _MSC_VER
#include <intrin.h>
#ifdef EASY3D_OS_64_BITS
#pragma intrinsic(_BitScanForward64)
#pragma intrinsic(_BitScanReverse64)
#else
#define _BitScanForward64 _BitScanForward
#define _BitScanReverse64 _BitScanReverse
#pragma intrinsic(_BitScanForward64)
#pragma intrinsic(_BitScanReverse64)
#endif
#endif
I would love to use your library - it looks great. But the GPL Licence would poison our complete code base.
Is there any chance that you change the license to a more liberal (like Apache 2)?
Hi Liangliang,
Is there any interface of your framework can produce rendering depth image from point cloud and camera intrinsic and camera pose?
The input is camera intrinsic, camera pose and point cloud (only XYZ), and the output is the depth image (the width and height are the same as camera image, and there is depth value of some of these pixels)
Best,
Yu
hi,
Can draw image in center of viewer background? and access to the camera? like zoom in and zoom out.
thanks.
I compiled easy3d application `Mapple' using VC2017 x64.
When I used the Delaunay Triangulation 2D (only XY) to create mesh, the application crashed.
Hi,
Is there a support for other than default line width 1.0f ?
I tried adding glLineWidth support to drawable.cpp but opengl complained for invalid value ..
Thanks
Is there any helper for rigging in the library? I am looking an easy to use library to show animated meshes. I like this library because it is really easy to use, but I cannot find if it is possible to use bones/animations and so on.
Hello!
Im using Ubutnu 18.04 and terminal versions of cmake and make.
Im clone your repo and
mkdir build && cd ./build
sudo cmake ..
cd ../
sudo make
then get this error
In file included from /home/garaev/Projects/Easy3D/easy3d/viewer/viewer.cpp:62:0:
/home/garaev/Projects/Easy3D/easy3d/util/timer.h: In lambda function:
/home/garaev/Projects/Easy3D/easy3d/util/timer.h:206:31: error: ‘bind’ is not a member of ‘std’
auto f = std::bind(func, owner, std::forward(args)...);
^~~~
/home/garaev/Projects/Easy3D/easy3d/util/timer.h:206:31: note: suggested alternative: ‘find’
auto f = std::bind(func, owner, std::forward(args)...);
^~~~
find
/home/garaev/Projects/Easy3D/easy3d/util/timer.h: In lambda function:
/home/garaev/Projects/Easy3D/easy3d/util/timer.h:238:27: error: ‘bind’ is not a member of ‘std’
auto f = std::bind(func, owner, std::forward(args)...);
^~~~
/home/garaev/Projects/Easy3D/easy3d/util/timer.h:238:27: note: suggested alternative: ‘find’
auto f = std::bind(func, owner, std::forward(args)...);
^~~~
find
/home/garaev/Projects/Easy3D/easy3d/util/timer.h: In lambda function:
/home/garaev/Projects/Easy3D/easy3d/util/timer.h:273:31: error: ‘bind’ is not a member of ‘std’
auto f = std::bind(func, owner, std::forward(args)...);
^~~~
/home/garaev/Projects/Easy3D/easy3d/util/timer.h:273:31: note: suggested alternative: ‘find’
auto f = std::bind(func, owner, std::forward(args)...);
^~~~
find
easy3d/viewer/CMakeFiles/viewer.dir/build.make:686: recipe for target 'easy3d/viewer/CMakeFiles/viewer.dir/viewer.cpp.o' failed
make[2]: *** [easy3d/viewer/CMakeFiles/viewer.dir/viewer.cpp.o] Error 1
CMakeFiles/Makefile2:609: recipe for target 'easy3d/viewer/CMakeFiles/viewer.dir/all' failed
make[1]: *** [easy3d/viewer/CMakeFiles/viewer.dir/all] Error 2
Makefile:83: recipe for target 'all' failed
make: *** [all] Error 2
How can i solve it?
hi,
can you implement 3d model tranform by rotation matrix? (like cloud compare->edit->apply transformation)
thanks.
Hello, Thank you for your work. I have been starred this repo for a long time. Recently, I have a demand to use the code about effcient ransac but I met some problem. As it happens that I found you add a tutorial about the planeextraction.So I make and test it with the data you provide - building_cloud.bin. The problem is sometimes that the plane extraction can't work and the terminal output as below. Sometimes works. It is so strange. Do you have any advice? Thank you very much! By the way ,I also use the source code of effcient ransac in my project, the problem in my project is that with same data and parameter, the number of detected plane can be 0 or other. It is also very strange.
Failed one
terminal output "ERROR IN GLOBAL REBUILD"
Success one
No where I could found are the dependencies listed. After trying to compile i found at least GLEW.
Hello,
I was using one of the previous version of this library and everything was working very nice.
I was trying to build and run the newest version, however i have problem to build it.
I am using QtCreator in order to build the code however it seems that there are some errors in a header file called portable-file-dialogs.h. I am using QtCreator in windows machine. Here are some of the errors:
Easy3D-master\3rd_party\portable_file_dialogs\portable_file_dialogs.h:677: error: 'lstrcpyW_instead_use_StringCbCopyW_or_StringCchCopyW' was not declared in this scope
lstrcpyW(ofn.lpstrFile, m_wdefault_path.c_str());
Easy3D-master\3rd_party\portable_file_dialogs\portable_file_dialogs.h:952: error: invalid use of incomplete type 'IFileDialog {aka struct IFileDialog}'
hr = ifd->GetResult(&item);
C:\Qt\Tools\mingw730_64\x86_64-w64-mingw32\include\combaseapi.h:79: error: invalid static_cast from type 'IFileDialog*' to type 'IUnknown*'
static_cast<IUnknown *> (*pp);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Do you have any idea of how to handle the errors below?
Thanks a lot for your time.
Hi, I implemented octree and i want to apply culling. Is this possible to implement culling in easy3d. If yes, how???
Hi,
When I run the viewer->run() inside a thread (in order no to block my main program execution) imgui crash
`Visualizer::Visualizer()
{
viewer = new easy3d::ViewerImGui("str");
// this works
// viewer->run();
// this doesnt ...
std::thread th1(&Visualizer::StartViewer, this);
}
void Visualizer::StartViewer()
{
viewer->run();
}
`
The crash error is
terminate called without an active exception
ERROR: ImGui_ImplOpenGL3_CreateDeviceObjects: failed to compile vertex shader!
ERROR: ImGui_ImplOpenGL3_CreateDeviceObjects: failed to compile fragment shader!
ERROR: ImGui_ImplOpenGL3_CreateDeviceObjects: failed to link shader program! (with GLSL '#version 150
')
When I run viewer->run() directly, I can see the viewer window - but then run() is blocking and execution stops ..
Any idea how to fix that ?
Thanks
Lior
Hi, I want to use this framework, but I found that there are not many materials. Can you give me some links?
And I would like to produce 2D image from mesh grid map in a camera frame, can this framework work?
Best,
Yu
Build stops with C++ errors. I just wanted to give it a try, so I haven't spent the time to trace the causes of the errors down.
can not draw Transparency(AverageColorBlending::draw) model over image.
Is it possible to implement the following functions with modern OpenGL pipeline?
how to get model and camera scale?
When I debug the mesh processing, I hope that node or element Id should be shown. Does Easy3D supply this function?
Hi,
Great work! I think it's one of the simplest and clearest 3D Rendering projects out here!
Can anyone point me to the place where I can change the "point" size in the cloud point view ?
Thanks!
Hello, can i import mesh as .obj file and export as image? Dont find this opportunity in tutorials.
Hi Suppose I would like to assign a color to a point clouds points according to its location. How do I access the vertex location in the cloud vertices iterator. Something along the lines of ...
for (auto v : gccloud->vertices())
{
gccolors[v] = vec3(v.pos[0],0,0);
}
Thanks
First of all impressive work: efficient and organized. Thank you!
I often find myself trying to view 3D data through a Windows remote desktop connection (RDC), as the data is too big or the time lost to download it locally is an overhead. The problem with RDC is that it does not have access to the GPU, and so any OpenGL app fails to open. However DirectX is still available and works great. There are a number of solutions:
Can you pls add support for Angle to Easy3D? This will be a feature that will additionally differentiate your viewer from anything out there, plus will help me and many other using RDC on daily bases.
hi, dear.
can you give me source code of mapple?
thanks,
jignesh
how to export step from Obj?
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.