Damien will know better, but i guess that's got to do with vray not rendering native rhino materials properly (i thought it did). I don't have it installed so i can't check it out. I'm using Brazil for rhino which is great and renders rhino native materials as fast as Brazil specific ones. Maybe it's possible to make a script that creates an vray material from a rhino material. I think the next release of vray will use the new RDK stuff ....maybe then it will work.
On May 4, 1:34 am, Marc Syp <marc....@gmail.com> wrote: > Visose - > > Thanks for that. > > Unfortunately I can get the component to bake and I see the materials > when I render in Rhino Render and Flamingo, but if I try Vray for > Rhino or 3dsMax, I get nothing but grey. Any ideas? > > Thanks, > Marc > > On May 3, 9:33 pm, visose <vic...@gmail.com> wrote: > > > Here you go:http://grasshopper3d.googlegroups.com/web/bakematerial.ghx > > > On May 3, 9:07 pm, Marc Syp <marc....@gmail.com> wrote: > > > > Hey guys... > > > > I'm not able to get either of these scripts to work by modifying the > > > original. It's definitely my VB.NET ignorance, I'm still a beginner. > > > Can someone post a .ghx of this VB component? > > > > Thanks, > > > Marc > > > > On Apr 15, 2:25 pm, fraguada <fragu...@gmail.com> wrote: > > > > > Damien, Visose...great stuff...... to do both: > > > > > If blnBake Then > > > > > 'Bake Object > > > > Dim mObj As New MRhinoBrepObject > > > > mObj = doc.AddBrepObject(obj) > > > > > 'Set Material > > > > Dim att As New MRhinoObjectAttributes(mObj.Attributes()) > > > > att.setmaterialsource(1) > > > > att.m_material_index = doc.m_material_table.AddMaterial > > > > (material) > > > > > 'Modify the attributes > > > > Dim objref As New MRhinoObjRef(mObj.Attributes.m_uuid) > > > > doc.ModifyObjectAttributes(objref, att) > > > > > Dim att2 As New MRhinoObjectAttributes(mObj.Attributes()) > > > > att2.SetColorSource(1) 'setcolorsource to From > > > > Object > > > > Dim rColor As New OnColor (color) 'make OnColor > > > > att2.m_color = rColor 'Set ObjectColor > > > > > doc.ModifyObjectAttributes(objref, att2) > > > > > End If > > > > > -This works with my tossed together knowledge of vb.net/rhino sdk (is > > > > there a cleaner way?... Tocolorcurves would it work by changing the > > > > MRhinoBrepObject to its curve correspondent? I have not tried, just > > > > wondering coneptually... > > > > > Luis > > > > > On Apr 13, 8:36 pm, Pablo Morales <olba...@gmail.com> wrote: > > > > > > and i can't open the file with grasshopper can you upload a image of > > > > > the > > > > > grasshopper view please > > > > > > Thanks, Pablo Morales > > > > > > On Mon, Apr 13, 2009 at 8:11 PM, Pablo Morales <olba...@gmail.com> > > > > > wrote: > > > > > > hi, my version of grasshopper is 0.5.0099 > > > > > > > On Mon, Apr 13, 2009 at 7:41 PM, visose <vic...@gmail.com> wrote: > > > > > > >> I modified the above script to actually bake the material for > > > > > >> rendering purposes. You need to add an input called 'material' and > > > > > >> connect it to the shader. > > > > > > >> If blnBake Then > > > > > > >> 'Bake Object > > > > > >> Dim mObj As New MRhinoBrepObject > > > > > >> mObj = doc.AddBrepObject(obj) > > > > > > >> 'Set Material > > > > > >> Dim att As New MRhinoObjectAttributes(mObj.Attributes()) > > > > > >> att.setmaterialsource(1) > > > > > >> att.m_material_index = doc.m_material_table.AddMaterial > > > > > >> (material) > > > > > > >> 'Modify the attributes > > > > > >> Dim objref As New MRhinoObjRef(mObj.Attributes.m_uuid) > > > > > >> doc.ModifyObjectAttributes(objref, att) > > > > > > >> End If > > > > > > >>Damien, in relation to my problem about baking vertex colors. At > > > > > >>least > > > > > >> i can render something using this method and lots sub-surfaces (one > > > > > >> per texel). It will be ridiculously inefficient though :P > > > > > > >> On Apr 13, 4:01 pm, damien_alomar <dominos...@gmail.com> wrote: > > > > > >> > Some one asked this a little while ago, so I cooked up a custom > > > > > >> > definition for it. > > > > > > >> >http://grasshopper3d.googlegroups.com/web/bakeWcolor.ghx?hl=en&gda=Bx. > > > > > >> .. > > > > > > >> > -Damien > > > > > > >> > On Apr 12, 11:07 am, Pablo Morales <olba...@gmail.com> wrote: > > > > > > >> > > hi, > > > > > >> > > Is posible to conserve the colour of grasshopper when i bake? > > > > > >> > > I mean > > > > > >> is > > > > > >> > > posible to render the colours of grasshopper in Rhino? > > > > > > >> > > Thanks