[Closed] Delete Visibility Track
You could assign it a new controller, or try assigning it “undefined” (if that’s possible?)
$mynode.visibility = bezier_float()
Seems like you can’t delete the visibility track from the Track View through MAXScript.
So I’ve created a MAXScript extension in C++ that exposes a function that just does that. Just copy the DelVisTrack.dlx file into your 3dsmax plug-ins directory and once in MAX, say you have a node named “Box01” with the Visibility track set. To remove it, you just write:
delVisTrack $Box01
If everything is ok, it will return true, else false.
It’s not too much tested but seems to work fine.
Hope that helps!.
Cool, that is what I thought about not being accessable via script, thanks for exposing this feature.
Things I’ve tried:
$.visibility = undefined –sets the visibility value to -1
$.visibility.controller = undefined – Type error: Assign needs controller, got: undefined
[color=White]delete $.visibility[/color] – No “delete” function for false
[color=White]delete $.visibility.controller[/color] – No “delete” function for Controller:Bezier_Float
I’m glad it works!.
Here’s the source code for this little plugin. The main functionality is in the file delvistrack.cpp. As you can see is really simple!.
Greets.
PD: you should change the output directory in the VC++ project properties to something that match your needs.
Again the generosity and suport of the max community amazes me with its selflessness and willingness to make everyones max experience better.
Thanks again
I thought some comments would be nice to understand the source code!. Also, I’ve changed the output directories to Debug/Release folders. Much better, I think.
Ola Jonathan!
Great work on that C++ extension. I do a lot of Max Scripting myself, and would love to get into myself at some point, but it looks like a steep learning curve.
Anyway – sorry to highjack the thread, but … I’ve asked a C++ friend of a friend recently if she wouldn’t mind having a look at something for me, but as she’s not 3dsmax orientated, I woudn’t be surprised if she passes on this one.
Basically it’s an amend to the path controller, from “% along path” to “Distance along path”. At the moment I’m using a list and script controller combination to achieve the same thing, which makes animating a lot easier; you can adjust the spline and the animation doesn’t change.
I’ve scanned the path_cnstrnt.cpp and control.rc files in the SDK samples and it looks promising, but I wouldn’t know where to start, or what to do if I did.
Is this something that’s possible? And is it a trivial or a very difficult task?
If my friend isn’t able to take this on, woudl yo ube interested in discussing this possibility of making amends? I’d be more than happy to trade skills; I also do a lot of web development work.
Thanks for reading!
All the best,
Dave Stewart