Forums > Jitter index matrix example?

December 13, 2013 | 6:52 pm

Hi everyone,

I’m trying to figure out how to use an index array to tell which vertices of my vertex array to draw.

Could anybody share any working examples of how to go about creating such an index array?

I’ve been searching in the forums and beyond, but haven’t been able to find any sort of patch that uses an index array or explains how to do it. Any help would be greatly appreciated!


December 16, 2013 | 12:49 am

First of all, I have no idea what the answer to your question is. But I’m still going to try to help.

I’m trying to figure out how to use an index array to tell which vertices of my vertex array to draw. requires a matrix to create a geometric surface, so keep that in mind.

If you’re going to have a "normal-average-everyday" 3d model/animation then you should definitely model it in something like Blender or Maya and then load the model in with

However, you might want to do something more special when creating your 3D object, you could try generating the object with Take a look at Day 5 at the following link:

This patch explores the use of jit.gen to generate 3D matrices for use with

Hopefully this helps!

|\|athan |)anziger .(om

December 16, 2013 | 11:05 am

basic example:

— Pasted Max Patch, click to expand. —


December 16, 2013 | 11:22 am

Thanks Rob, this is what I was looking for.

Now, I’d like to tell to only use those coordinates in the vertex array that have z = 0. Any idea how I would go about doing that?

My first idea was to iterate over the vertex array and test for z = 0, then put those coordinates that pass into another matrix which functions as the index array. Do you think that would work? I don’t have access to Max right now, so I can’t try it out at the moment…

Thanks for the help!

January 22, 2015 | 3:39 am


I was looking to increase performances of my mesh generation in using the indexation vertices technics. I found your patch above usefull to see how it works but for me it won’t increase performances because we don’t use the shared vertices.

For me the correct example for indexation vertices will be something like this


— Pasted Max Patch, click to expand. —


Can you please tell me if i’m right / wrong or if it is the same or if you make something internal to the gl.mesh object to find automatically the shared vertices and ignore them?


  • This reply was modified 1 year by  nesifao.
  • This reply was modified 1 year by  nesifao.
January 22, 2015 | 10:54 am

hi nesifao. no, there is no mechanism in gl.mesh that automatically ignores shared vertices. so yes, your example is a better demonstration of this feature.

Viewing 6 posts - 1 through 6 (of 6 total)

Forums > Jitter