Comments (5)
Hi, you could use offline rendering to render the two meshes into two buffers of equal size, using the same modelview/projection matrix. Once you have this, you just need to count the pixels that are hit in both buffers (hence by both shapes) and normalize by the total amount of pixels hit by one of the two shapes.
This whole thing is not implemented in cinolib, but it is actually very close to what I do for the computation of the Ambient Occlusion (https://github.com/mlivesu/cinolib/blob/master/include/cinolib/ambient_occlusion.cpp). In that case I am rendering a single mesh from multiple points of view (I am iterating over a vector of view directions). In your case you'd have a single view direction, but two meshes and two buffers. It should be fairly easy for you to adjust that code to do what you need
from cinolib.
Thank you very much for your reply.
Sorry for this other dummy question, but when trying to compile/link examples (such as 'ambient_occlusion' one), I get a linking error in MVS2017/Win10 (cinolib.lib not found). But I thought it was a header-only lib, with no output lib file ?
Thank you again.
from cinolib.
Indeed cinolib is header only and is known to compile on MVS17 (see the associated workflow). Perhaps you are not doing something right. As a starter, try to use the CMakeLists.txt in the examples folder (the one that computes them all). It should succeed
from cinolib.
Thank you.
I used this time the cmakelists from the whole exercices folder this time, as recommended, and cmake was able to build a VS project with all the correct settings and then no more build not link errors.
Strange that it was not the same using the cmakelists file from the (single) exercise folder..
last question about the exercise sample: I tried the exercise of tetmesh viewer, and I am not able to see the expected toolbar of settings in 3d window (slider for cutting plane, for seeing the internal meshing). Do I need to press a specific key to hide/show this settings control dialog ?
from cinolib.
Sorry. I just noticed that the help for describing key functions was part of the console window. And it shows that TAB key controls the hide/show of the side bar.
from cinolib.
Related Issues (20)
- Is it possible to offset a mesh preserving its sharp edges? HOT 6
- How to generate a cinolib? HOT 2
- Cut a volume mesh based on embedded level set HOT 15
- no member named 'update_hex_quality' HOT 3
- OpenGL rendering: soft shadows HOT 3
- How to use remesh_Botsch_Kobbelt_2004 without gl HOT 3
- Orient a closed surface mesh HOT 4
- Custom data in Tetmesh HOT 1
- All-hexahedral meshing? HOT 1
- Embed a polyline into a mesh HOT 4
- error when run sliced_CLI_loader HOT 1
- CMD + click ,What button is cmd in surface_painter project HOT 1
- Link errors HOT 1
- information HOT 8
- Imgui control hidden HOT 2
- How to implement algorithms such as QEM HOT 2
- Support for Semantic Versioning HOT 3
- intersection when rendering a .mesh file HOT 5
- can we train an AI assisatnt for CAX? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cinolib.