Exporter for Rhinoceros

General discussion regarding exporter development in general.

Moderators: Ratow, coordinators

Re: Exporter for Rhinoceros

Postby Lord Crc » Tue Jun 15, 2010 10:36 am

A few issues:

the shape in the lxs file you attached has the wrong number of knots, however the code you pasted does not. However both miss one "P" point (44, should be nu*nv=5*9=45).

In addition there seems to be a bug in the nurbs code causing an out-of-bounds array access. However since I can't guess the missing "P" I won't be able to see if I have fixed it or not.
May contain traces of nuts.
User avatar
Lord Crc
Developer
 
Posts: 4455
Joined: Sat Nov 17, 2007 2:10 pm

Re: Exporter for Rhinoceros

Postby Lord Crc » Tue Jun 15, 2010 10:52 am

It doesn't help that the nurbs code isn't described in the book, other than in the list of supported shapes and parameters :(
May contain traces of nuts.
User avatar
Lord Crc
Developer
 
Posts: 4455
Joined: Sat Nov 17, 2007 2:10 pm

Re: Exporter for Rhinoceros

Postby exvion » Tue Jun 15, 2010 12:01 pm

LordCrc, I fixed count points and knots, errors in log disappeared.
greenshot_2010-06-15_21-06-49.png


patro, How create one nurbs surface in Rhino?
Attachments
LuxRhino_sphere.lxs
(4.52 KiB) Downloaded 18 times
exvion
 
Posts: 84
Joined: Mon May 18, 2009 12:33 pm
Location: Russia, Vologda

Re: Exporter for Rhinoceros

Postby Lord Crc » Tue Jun 15, 2010 12:34 pm

Great! Now I can take a stab at fixing the nurbs code :)
May contain traces of nuts.
User avatar
Lord Crc
Developer
 
Posts: 4455
Joined: Sat Nov 17, 2007 2:10 pm

Re: Exporter for Rhinoceros

Postby Lord Crc » Tue Jun 15, 2010 4:27 pm

Right, with the AV fixed I get the same as you.

In order to determine where the issue is it would be preferable if you could output a single nurbs patch similar to what's shown here: http://wiki.blender.org/index.php/File: ... n20-Ex.png It doesn't have to go all the way to the edges (endpoint in blender), just general setup. Then export one with order 2 and order 3, so we can have a closer look :)
May contain traces of nuts.
User avatar
Lord Crc
Developer
 
Posts: 4455
Joined: Sat Nov 17, 2007 2:10 pm

Re: Exporter for Rhinoceros

Postby exvion » Wed Jun 16, 2010 6:21 am

greenshot_2010-06-16_15-18-00.png
Attachments
LuxRhino_surface_patch.lxs
(3.41 KiB) Downloaded 36 times
exvion
 
Posts: 84
Joined: Mon May 18, 2009 12:33 pm
Location: Russia, Vologda

Re: Exporter for Rhinoceros

Postby patro » Wed Jun 16, 2010 6:30 am

exvion, that's awesome :)
User avatar
patro
 
Posts: 1798
Joined: Fri Feb 29, 2008 9:06 pm
Location: mount Etna

Re: Exporter for Rhinoceros

Postby tomb » Wed Jun 16, 2010 9:13 am

Cool :)

@exvion: you're probably still at a "play around with it" stage, but do let us know if you think you'll be working on this enough to have a separate forum/mercurial repository!
User avatar
tomb
Developer
 
Posts: 1919
Joined: Thu Oct 11, 2007 4:23 pm
Location: Oslo, Norway

Re: Exporter for Rhinoceros

Postby patro » Thu Jun 17, 2010 4:10 pm

hi,
I hope some one can help me understand..

Luxrender recognize the nurbs geometry....

but what Luxrender finally display in the window is it a rendered nurbs or a mesh?

after parsing the nurbs data does Luxrender mesh the nurbs geometry?

for example exvion had exported a nurbs with 25 knots, the rendered patch have a nice smooth :)
but if I export similar polygonal surface.. probably I'll get a faceted one! to achieve similar result... I must add an smooth modifier!
this will increase the number of vertex.... that are also to see in the lxs file!

so... what does Luxrender do with the less nurbs data to recognize a so smooth surface?

thanks

Patro
Last edited by patro on Thu Jun 17, 2010 5:19 pm, edited 1 time in total.
User avatar
patro
 
Posts: 1798
Joined: Fri Feb 29, 2008 9:06 pm
Location: mount Etna

Re: Exporter for Rhinoceros

Postby Lord Crc » Thu Jun 17, 2010 5:17 pm

patro wrote:Luxrender recognize the nurbs geometry.... what Luxrender finally display in the window is it a rendered nurbs or a mesh?


Currently it triangulates the nurbs using a fixed number of "steps" in both directions (30, if I read the code right). Considering the complexity of directly rendering a nurbs surface triangulation is probably the best way to go, however a fixed triangulation resolution is non-optimal. It shouldn't be too hard to triangulate based on curvature (and optionally resulting size of the triangles), feel free to add a feature request once the exporter's up and running, so we have something to test with :).
May contain traces of nuts.
User avatar
Lord Crc
Developer
 
Posts: 4455
Joined: Sat Nov 17, 2007 2:10 pm

PreviousNext

Return to General

Who is online

Users browsing this forum: No registered users and 0 guests