GL: Nurbs surface trimming? Examples of precise mesh generation?
I’m on a new architectural design project where audio analysis data morph 3D surfaces. Last year I had a similar project (some posts about it in the forum) where I used nurbs surfaces and modulation of the control points. This time round it has to generate more complex shapes. For example with cut-out’s and splits in the surface.
The openGL red book refers to nurbs surface trimming to make cut-outs: http://fly.srk.fer.hr/~unreal/theredbook/chapter11.html. I don’t find a reference to this in Jitter though. Is it implemented?
Unless I overlook something I don’t think jit.gl.nurbs surfaces will do for this project. I’m looking at jit.gl.mesh instead. My problem is that all the examples I can find use noise or sampled video/audio data as fuzzy input to the mesh object. None illustrate the use of the vertex, texcoord, normal, color, specular, edgeflag, tangent, bitangent, and index data inputs for precise/designed mesh control.
Does anyone know of examples of tutorials demonstrating this?
Can the geometry shaders be of any help here? The resulting shapes need to be exported as obj models.
As always, all help very much appreciated! Tanx Dieter
i can only answer question 2, and take a long shot at 3…
one way of getting geometry into jit.gl.mesh is to use the matrix output function of 3d jitter objects, which can then be processed via noise or audio modulation (for example).
the matrixoutput flag outputs a matrix of 12 planes, which can subsequently be chopped into relevant bits… the first 3 planes contain the geometry data.
there arent that many detailed examples of this type of processing as it seems to be quite project specific… i assume this is because it would be a lot of work to come up with a generic approach.
shaders are good because they get the gpu to do the donkey work, but writing geometry shaders is not that easy unless you are already well versed in shader languages. check some of vade’s shaders for examples of geometry processing.
finally exporting to OBJ could be tricky, search the forum for a post on this… i only had a brief look at the post, but it’s not that straightforward.
hope that is of some use!
hi justin, tanx for your reply
ideally i wouldn’t use matrixoutput of jitter GL objects but generate my own geometry matrices algorithmically. at the moment i’m in the dark about how to do that precisely though. i guess i’ll try to reverse engineer the mesh outputs generated by the matrixoutput data of GL objects to deduce how it works exactly.
this section of the redbook on vertex arrays might be useful:
gl.mesh is basically a wrapper for drawing vertex arrays (or VBO’s if supported). which means you just provide data per vertex in a matrix, and pass to the correct inlet. probably best to just start with position data, and try and make some precise manipulations using matrices, before worrying about the rest.
pelado’s recent patch comes to mind as a good example.
great, you nailed 2 issues for me there. the red book entry is exactly what i need. it s weird coz i read through the red book. seems like i overlooked it, or didn’t know yet that i needed it when i did, or i read the 1.0 specification where vertex weren’t implemented yet: http://fly.srk.fer.hr/~unreal/theredbook/chapter02.html seems the last option is the case…
and about pelado’s example, in another current project i’m creating similar complex gradient patterns. i had to use gradient images drawn in illustrator and used as masks for blending using slabs. next step was going to be working out how to do it all generated in max. guess i ve got my answer right there!
Forums > Jitter