Giter VIP home page Giter VIP logo

tvgl's People

Contributors

atgrier avatar brmasstest avatar massonib avatar mattmedemalabs avatar mattmedemalabs-zz avatar micampbell avatar mvelayati avatar slindberg avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

tvgl's Issues

PolygonalFace

Hi,

I am new user of TVGL.
I am very interested in this rich library, however I am interested in particular subject,

Is it possible to get very simple example how to create 3d polygon that has faces with more than 3 or 4 vertices?

Thank you

Example for 2D Triangulation

Hello,

I've tried to generate a 2D triangulation with this library, but I can't seem to figure out how to use TVGL.TriangulatePolygon.Run2D:

var points = new[]
{
	new List<TVGL.Point>
	{
		new TVGL.Point(1, 1),
		new TVGL.Point(1, 5),
		new TVGL.Point(5, 5),
		new TVGL.Point(5, 1)
	}
};

var isPositive = vertices.Select(vl => false).ToArray();
var orderedPoints = TVGL.TriangulatePolygon.OrderLoops2D(points, ref isPositive).Select(l => l.ToArray()).ToArray();

List<List<int>> groupsOfLoops;
var triangles = TVGL.TriangulatePolygon.Run2D(orderedPoints,
	out groupsOfLoops,
	ref isPositive);

So, this is my attempt to triangulate a rectangle, but Run2D always throws an exception with the message "Triangulation failed after 3 attempts."

Is there anything I'm doing wrong?

Thanks in advance!

P.S.: For what it's worth, I did manage to get a valid triangulation of concave polygons with holes from the TVGL.TriangulatePolygon.Run method. The only times I'm getting the "Triangulation failed after 3 attempts." message from Run is when the polygon has intersecting edges, or if I pass in a "polygon" with less than three vertices (none of which will happen in my actual use case).

Any improvement for fast slicing?

Thanks for this great project. It works great for my application, but I'd like to know any improvement is possible to make slice the model fast? I tried different STL files from thingiverse.com and it takes about 70 sec to load a model with 1.3M faces and another 60 sec to get a single slice. I hope I'd contribute this project, but I'm still learning C#.

Thanks!

Whether a point is inside a 3d polygon

Hello!
I'm new here. I have *.stl file with some model. I need to find all the points inside this model.
I found a question that refers to MiscFunctions.cs file.
Firstly, I read all the vertices from file and create convex hull.

var result = StlHelper.ReadFile(stlPath); // List<Vertex>
var hull = ConvexHull.Create(result);
var tessellatedSolid = new TessellatedSolid(...); // <---

Later I try to use MiscFunctions.IsPointInsideSolid method that required TessellatedSolid parameter.
Is it right? Is there an example of checking whether a point is inside a 3d polygon?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.