meshlabjs | javascript client based mesh processing tool | 3D Animation library
kandi X-RAY | meshlabjs Summary
kandi X-RAY | meshlabjs Summary
A javascript, client-side, mesh processing tool. Inspired by the well known [MeshLab] [MeshLabJS] is built using, for all the mesh processing tasks, the c++ [vcg library] compiled into asm.js using [emscripten] and it relies on [three.js] for rendering. [MeshLabJS] is developed by the [Visual Computing Lab] vcg.isti.cnr.it) of [ISTI - CNR] www.isti.cnr.it) and by the students of the FGT course. Some more info on the code are in the [Documentation Page] Issues and bugs can be filed in the github [issue] page.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of meshlabjs
meshlabjs Key Features
meshlabjs Examples and Code Snippets
Community Discussions
Trending Discussions on meshlabjs
QUESTION
I'm trying to make a cube, which is irregularly triangulated, but virtually coplanar, shade correctly.
Here is the current result I have:
With wireframe:
Normals calculated in my program:
Normals calculated by meshlabjs.net:
The lighting works properly when using regular size triangles for the cube. As you can see, I'm duplicating vertices and using angle weighting.
lighting.frag
ANSWER
Answered 2020-Feb-21 at 20:51As mentioned in the other answers the problem is your mesh normals.
Computing an average normal, like you are doing currently, is what you would want
to do for a smooth object like a sphere. cgal
has a function for that CGAL::Polygon_mesh_processing::compute_vertex_normal
For a cube what you want is normals perpendicular to the faces
cgal
has a functoin for that too CGAL::Polygon_mesh_processing::compute_face_normal
To debug the normals you can just set fragColor = vec4(norm,1);
in mainmesh.frag
. Here the cubes on the left have averaged (smooth) normals and on the right have face (flat) normals:
And shaded they look like this:
shading has to work for any kind of mesh (a cube or any organic mesh)
For that you can use something like per_corner_normals whitch:
Implements a simple scheme which computes corner normals as averages of normals of faces incident on the corresponding vertex which do not deviate by more than a specified dihedral angle (e.g. 20°)
And this is what it looks like with a angle of 1°, 20°, 100°:
QUESTION
I'm following this tutorial, and adjusting the Celery-background related code to my project.
In my case I am operating in a Docker environment, and I have a secured site (i.e. https://localhost).
I adjusted the code for secure connection as follows:
ANSWER
Answered 2020-Feb-18 at 18:13The problem with secure connection was because the ssl keys were not available to the web container.
I fixed it by changing docker-compose.yml
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install meshlabjs
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page