<p dir="ltr">I use MOI as my main nurbs to mesh converter and it uses ngons a lot not for holes but surfaces.</p>
<p dir="ltr">Claas</p>
<div class="gmail_quote">On Jul 26, 2014 8:51 AM, "Dalai Felinto" <<a href="mailto:dfelinto@gmail.com">dfelinto@gmail.com</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi,<br>
<br>
> * Does anyone know of good example code for making a BMesh out of n-gons? N-gons would make the meshes produced by Alt+C *much* cleaner.<br>
<br>
Be aware that N-gons don't support holes (at the moment), so you may<br>
get buggy meshes during this conversion. But as Sergey said, you don't<br>
need to convert the nurbs to ngons.<br>
<br>
Cheers,<br>
Dalai<br>
--<br>
<a href="http://blendernetwork.org/dalai-felinto" target="_blank">blendernetwork.org/dalai-felinto</a><br>
<a href="http://www.dalaifelinto.com" target="_blank">www.dalaifelinto.com</a><br>
<br>
<br>
2014-07-26 8:39 GMT-03:00 Sergey Sharybin <<a href="mailto:sergey.vfx@gmail.com">sergey.vfx@gmail.com</a>>:<br>
> Hi,<br>
><br>
> It's cool to hear you're doing progress, but what about committing the stuff<br>
> to Git? Last commit was done on Monday and in the report you claim having<br>
> progress since that. Commit the stuff even if it's not production ready.<br>
> I've asked about this several times already.<br>
><br>
> Before you go to importing or making improvements to curve->mesh conversion<br>
> i'll demand wrapping existing code up, making so it's used in blende (and<br>
> commit everything!)r and preparing demo files for this.<br>
><br>
> As for ngon examples, you just need to fill in mpoly and mloop arrays<br>
> actually. MOD_boolean_util.c has examples (it operates with DerivedMesh, but<br>
> it's almost the same as you need for curve->mesh conversion).<br>
><br>
> Also, what are the plans for the next week?<br>
><br>
><br>
> On Sat, Jul 26, 2014 at 1:43 PM, Jonathan deWerd <<a href="mailto:jjoonathan@gmail.com">jjoonathan@gmail.com</a>><br>
> wrote:<br>
>><br>
>> This week was largely eaten up by a task that I thought would be a quick<br>
>> copy/paste job but turned into a morass of debugging math code. Fortunately<br>
>> that part is done -- and the result is much prettier smooth curves:<br>
>><br>
>> <a href="http://wiki.blender.org/index.php/User:Jjoonathan/New_NURBS_Eval" target="_blank">http://wiki.blender.org/index.php/User:Jjoonathan/New_NURBS_Eval</a><br>
>><br>
>> Progress This Week:<br>
>> * Finished the new evaluation code. Key features:<br>
>> * Computes any number of partial derivatives analytically<br>
>> * Immediate application 1: compute normals analytically = it looks smooth<br>
>> again :)<br>
>> * No nasty lighting artifacts near trim edges<br>
>> * No seams where curves touch/loop due to calculating normals at polygon<br>
>> corners<br>
>> * Immediate application 2: handle (literal) edge cases of eval points<br>
>> lying on knots correctly<br>
>> * Immediate application 3: uses 1/2 as many divisions, so possibly it's<br>
>> faster, although I didn't check<br>
>> * Future application: computing error bounds<br>
>> * Performed extensive verification of the new eval code<br>
>> * Mesh points coincide with Rhino surfaces<br>
>> * All 1st, 2nd (partial) derivatives agree with Mathematica's NURBS<br>
>> implementation (direction, amplitude correct).<br>
>> * Made progress on the trim curve tessellator.<br>
>> * NOTE: last week I mistakingly said that I had finished the trim curve<br>
>> tessellator when I actually meant to say that I had finished the surface<br>
>> tessellator.<br>
>> * Refactored the import code so that it can make detatched curves<br>
>> * Adjusted memory management & blenloader<br>
>> * The trim curve tessellator isn't a sticking point, I only got around to<br>
>> working on it again today. The eval code was the sticking point.<br>
>><br>
>> Things that were done that don't officially constitute progress:<br>
>> * Spent Thursday finishing rotation surface & interpolation surface<br>
>> chapters in P&T<br>
>><br>
>> Things that must be done before I can import the sample .3dm files:<br>
>> * Finish the trim curve tessellator<br>
>> * Rotation surfaces<br>
>><br>
>> Things I could use help on:<br>
>> * Does anyone know of good example code for making a BMesh out of n-gons?<br>
>> N-gons would make the meshes produced by Alt+C *much* cleaner.<br>
>><br>
>><br>
>><br>
>> On Jul 19, 2014, at 1:28 PM, claas kuhnen <<a href="mailto:info@ckbrd.de">info@ckbrd.de</a>> wrote:<br>
>><br>
>> So agree I am very excited about this<br>
>><br>
>> On Jul 19, 2014 1:27 PM, "Sergey Sharybin" <<a href="mailto:sergey.vfx@gmail.com">sergey.vfx@gmail.com</a>> wrote:<br>
>>><br>
>>> Seems to be rather nice progress. Would be cool if all the bits are<br>
>>> committed and some .blend in shared which demonstrates the stuff.<br>
>>><br>
>>><br>
>>> On Sat, Jul 19, 2014 at 4:31 PM, Jonathan deWerd <<a href="mailto:jjoonathan@gmail.com">jjoonathan@gmail.com</a>><br>
>>> wrote:<br>
>>>><br>
>>>> Progress:<br>
>>>> * Finished code to tessellate trim curves!<br>
>>>> see:<br>
>>>> <a href="http://wiki.blender.org/index.php/User:Jjoonathan/NURBS_In_Blender" target="_blank">http://wiki.blender.org/index.php/User:Jjoonathan/NURBS_In_Blender</a><br>
>>>> * Rewrote knot code to match the conventions in the math literature,<br>
>>>> tested for compatibility by comparing meshes<br>
>>>> * Worked on adapting a better NURBS evaluation algorithm that can<br>
>>>> produce first and second derivatives (for normals and error bounds,<br>
>>>> respectively).<br>
>>>> it's still buggy.<br>
>>>> * Worked further on the NurbEdge interface to handle imported trim<br>
>>>> curves<br>
>>>> still working on code to match endpoints that are separated in<br>
>>>> UV space but coincide in R3 due to either wrapping in UV space (cyclic<br>
>>>> NURBS) or coving<br>
>>>><br>
>>>> Todo:<br>
>>>> * Finish tracking down the NaN-producing bugs in the new surface<br>
>>>> evaluator<br>
>>>> From there, should be easy to implement good normals<br>
>>>> * Finish NurbEdge so that it at least handles wrapping in UV space. This<br>
>>>> will allow importing of most .3dm files.<br>
>>>> * Implement revolution surfaces.<br>
>>>> Demo Claas's hairdryer model!<br>
>>>><br>
>>>> On Jul 12, 2014, at 11:14 AM, Jonathan deWerd <<a href="mailto:jjoonathan@gmail.com">jjoonathan@gmail.com</a>><br>
>>>> wrote:<br>
>>>><br>
>>>> > (Apologies if this is a duplicate email. I see a copy of this email in<br>
>>>> > gmail's "sent" folder but I don't see one in my inbox, so I'm sending<br>
>>>> > again.)<br>
>>>> ><br>
>>>> > Progress:<br>
>>>> > * Finished the code that traverses BReps from 3dm files and cuts them<br>
>>>> > into surfaces<br>
>>>> > * 2D Trim curves import as Nurb objects that are appended to a<br>
>>>> > NurbList in their parent surface<br>
>>>> > Just curves currently, I still have to get multi-part loops<br>
>>>> > working<br>
>>>> > Also they don't seem to be preserved by DNA even after calling<br>
>>>> > makesdna...<br>
>>>> > * Moved surf_gridmesh into bf_blenkernel, promoted curve.c to<br>
>>>> > curve.cpp (for future OpenNurbs use), fixed a few small bugs that caused,<br>
>>>> > moved the GLUT debug code into blender/tests, convinced CMake to build and<br>
>>>> > link it<br>
>>>> > * Wrote, debugged the method that builds the displist from the<br>
>>>> > gridmesh<br>
>>>> > * Timed it, see pretty graph a few emails back<br>
>>>> > * Started writing NurbEdge structure to handle in general the sewing<br>
>>>> > of trim edges and cyclic edges (e.g. so that spheres don't have seams)<br>
>>>> ><br>
>>>> > Next up:<br>
>>>> > * I still need to finish the code that tessellates the trim curves. I<br>
>>>> > didn't get much time to work on it today, so I'm planning to work on it<br>
>>>> > tomorrow as well.<br>
>>>> > * Get trim curves to load/save from .blend files by figuring out what<br>
>>>> > I'm doing wrong with makesdna<br>
>>>> > * Finish NurbEdge interface for defining edges to sew, get it in DNA<br>
>>>> > as well<br>
>>>> > * Use NurbEdge to implement revolution surfaces<br>
>>>> ><br>
>>>><br>
>>>> _______________________________________________<br>
>>>> Soc-2014-dev mailing list<br>
>>>> <a href="mailto:Soc-2014-dev@blender.org">Soc-2014-dev@blender.org</a><br>
>>>> <a href="http://lists.blender.org/mailman/listinfo/soc-2014-dev" target="_blank">http://lists.blender.org/mailman/listinfo/soc-2014-dev</a><br>
>>><br>
>>><br>
>>><br>
>>><br>
>>> --<br>
>>> With best regards, Sergey Sharybin<br>
>>><br>
>>> _______________________________________________<br>
>>> Soc-2014-dev mailing list<br>
>>> <a href="mailto:Soc-2014-dev@blender.org">Soc-2014-dev@blender.org</a><br>
>>> <a href="http://lists.blender.org/mailman/listinfo/soc-2014-dev" target="_blank">http://lists.blender.org/mailman/listinfo/soc-2014-dev</a><br>
>>><br>
>> _______________________________________________<br>
>> Soc-2014-dev mailing list<br>
>> <a href="mailto:Soc-2014-dev@blender.org">Soc-2014-dev@blender.org</a><br>
>> <a href="http://lists.blender.org/mailman/listinfo/soc-2014-dev" target="_blank">http://lists.blender.org/mailman/listinfo/soc-2014-dev</a><br>
>><br>
>><br>
>><br>
>> _______________________________________________<br>
>> Soc-2014-dev mailing list<br>
>> <a href="mailto:Soc-2014-dev@blender.org">Soc-2014-dev@blender.org</a><br>
>> <a href="http://lists.blender.org/mailman/listinfo/soc-2014-dev" target="_blank">http://lists.blender.org/mailman/listinfo/soc-2014-dev</a><br>
>><br>
><br>
><br>
><br>
> --<br>
> With best regards, Sergey Sharybin<br>
><br>
> _______________________________________________<br>
> Soc-2014-dev mailing list<br>
> <a href="mailto:Soc-2014-dev@blender.org">Soc-2014-dev@blender.org</a><br>
> <a href="http://lists.blender.org/mailman/listinfo/soc-2014-dev" target="_blank">http://lists.blender.org/mailman/listinfo/soc-2014-dev</a><br>
><br>
_______________________________________________<br>
Soc-2014-dev mailing list<br>
<a href="mailto:Soc-2014-dev@blender.org">Soc-2014-dev@blender.org</a><br>
<a href="http://lists.blender.org/mailman/listinfo/soc-2014-dev" target="_blank">http://lists.blender.org/mailman/listinfo/soc-2014-dev</a><br>
</blockquote></div>