SOuP Development
Register New Posts Donate
 
 
 


Reply
 
Author Comment
 
noizfactory

Avatar / Picture

SOuP Evangelist
Registered: 11/26/10
Posts: 557
Reply with quote  #1 
Hey guys,

Wanted to share a quick test that I'm doing using SOuP to detect tyre and terrain collision. Any feedback is welcome! Or if you can suggest more efficient way of doing this.

I noticed that towards the end of the frames when there is no more terrain geo left then the contact calculation doesn't output the desired result. In such cases setting the custom direction to -0.5 -1 0 instead of only Y down helps.

Cheers,
Sachin

 
Attached Files
ma soup_tyreContact_test.ma (217.70 KB, 74 views)


__________________
--
Sachin

pshipkov

SOuP Jedi
Registered: 11/01/10
Posts: 2,893
Reply with quote  #2 
Hey that's very nice.
That's how i usually do ground detection for tires when people ask me to make them car rigs and stuff.
Maybe you can prepackage this as a ready to use car wheel rig.
Don't forget to include the suspension - wheel can move only that much up-down.
Thanks for sharing man !
noizfactory

Avatar / Picture

SOuP Evangelist
Registered: 11/26/10
Posts: 557
Reply with quote  #3 
Thanks Peter. I was helping out some rigging friends and they did mention hooking it up with the suspensions. Yeah, I could prepackage this as an asset node and that should make it quite modular.
__________________
--
Sachin
pshipkov

SOuP Jedi
Registered: 11/01/10
Posts: 2,893
Reply with quote  #4 
feel free to make it available here :)
Or maybe put it in the SOuP example scenes archive.
Only if you feel comfy with that of course.
noizfactory

Avatar / Picture

SOuP Evangelist
Registered: 11/26/10
Posts: 557
Reply with quote  #5 
Peter, I'm trying to replace the Maya expression with pyExpression for more procedural control and to package it as an asset node. I connected the ponit1.outWeightPP to pyExpression and then in the node tried this:

import maya.cmds as mc
w = sorted(mc.getAttr("point1.outWeightPP"))
OF = w[0]

And connected translateY of the locator to OF. But executing the node returns this error:
Quote:

// Error: line 1: TypeError: file F:/cg/tools/plugins/maya/SouP/repo/downloaded/pyExpression_2013_02_08\pyExpressionCmd.py line 280: 'float' object is unsubscriptable //


Probably because I'm trying to pipe single float output into the float array output OF. Is there a way to hook this up? I was looking at resizeArray node to resize outWeightPP but I need the sorted array first.


__________________
--
Sachin
fxwriter

messy kitchen
Registered: 02/14/11
Posts: 84
Reply with quote  #6 
awesome scene file, thanks for sharing, I have to start using the pyExpression more often
pshipkov

SOuP Jedi
Registered: 11/01/10
Posts: 2,893
Reply with quote  #7 
yeah, i don't think it will work that way.
i was thinking to add array inputs but didn't have time for that.
Actually i want to redo the whole thing for better.
what "print w" returns ?
noizfactory

Avatar / Picture

SOuP Evangelist
Registered: 11/26/10
Posts: 557
Reply with quote  #8 
Quote:
Originally Posted by pshipkov
what "print w" returns ?

That returns the entire sorted array. It would have been cool to do this inside pyExpression or some other node in SOuP and maintain the procedural nature. Maya expression is not bad but poor for automating a digital asset.

Here's a playblast that shows more inclination stuff. It would be cool to also control the velocity on the way up/down the slope.


__________________
--
Sachin
pshipkov

SOuP Jedi
Registered: 11/01/10
Posts: 2,893
Reply with quote  #9 
looks cool.

with print w i wanted to check if you are getting array actually. so you do. the problem is you cannot output this as single attribute index. it has to be array element per output attribute index. just confirming it, we concluded that already.
I think what i will do is to provide inDoubleArray, inVectorArray and outDoubleArray and outVectorArray attributes at some point later.
noizfactory

Avatar / Picture

SOuP Evangelist
Registered: 11/26/10
Posts: 557
Reply with quote  #10 
Quote:
Originally Posted by pshipkov
I think what i will do is to provide inDoubleArray, inVectorArray and outDoubleArray and outVectorArray attributes at some point later.

Sounds cool Peter. However, will adding that allow me to do what I'm trying right now? Because I'd essentially still need a float array output and not just a single float (which is what I want).

__________________
--
Sachin
pshipkov

SOuP Jedi
Registered: 11/01/10
Posts: 2,893
Reply with quote  #11 
yes.
Previous Topic | Next Topic
Print
Reply

Quick Navigation:

Peter Shipkov ©2011 (pshipkov@yahoo.com)
Powered by Website Toolbox - Create a Website Forum Hosting, Guestbook Hosting, or Website Chat Room for your website.