I'm creating a python script to export keyframe data. When doing this I want to check to make sure that the keyframes are on either a position or a rotation track and ignore all others. I'm a little lost on how to do that check. I'm currently building this in xpresso with a python node and hoping to later convert it to a plug in. Here is my current code with comments.
import c4d
import math
def main():
# Get a list of all the animation tracks for the object
track = Object.GetCTracks()
#iterate through the list of tracks
for x in track:
#---Here I would like to check if this is rotation/position track or something that should be ignored ----
print x
#---- When x is printed I receive <c4d.CTrack object called 'Position . Y/Track' with ID 5350 at 0x0000025FC3AE2770> so I can see its position but I don't know how to sort that out -----
I think what I'm looking for is a GetTrackName or something along those lines?
Edit a_block: Added code tags