티스토리 뷰
Note Track은 Dope Sheet에서도 추가할 수 있다.
s = sphere() -- create a sphere
--
ntp1 = NoteTrack "PosNT1" -- create a note track
ntp2 = NoteTrack "PosNT2" -- create another note track
addNoteTrack s.pos.controller ntp1 -- apply first note track to sphere's pos controller
addNoteTrack s.pos.controller ntp2 -- apply second note track to sphere's pos controller
numNoteTracks s.pos.controller -- check number of note tracks on pos controller
hasNoteTracks s.pos.controller -- test to see if pos controller has note tracks
--
addNewNoteKey ntp1.keys 20 #select -- add key to first note track, and select the key
addNewNoteKey ntp1.keys 40 -- add another key to first note track
--
n = getNoteTrack s.pos.controller 1 -- retrieve first note track on the pos controller
nk=n.keys -- retrieve an instance of the note track key array
--
nk[2].value = "Yo What's Up" -- set value for second note key
nk[2].time = 10 -- change the time for second note key. Now first key
nk[1].selected = true -- select the first note key
sortNoteKeys nk -- changed the time of the note keys, so re-sort
nk.count -- check number of keys
nk -- display the note keys
--
-- To delete the note tracks and note keys
deleteNoteKey nk 1 -- delete first note key
deleteNoteKeys n.keys #allKeys -- delete all the note keys
deleteNoteTrack s.pos.controller ntp1 -- remove note track from pos controller
deleteNoteTrack s.pos.controller ntp2 -- remove note track from pos controller
'프로그래밍 > 잡탕' 카테고리의 다른 글
[Photoshop Script] JSON 쓰기 (0) | 2012.12.26 |
---|---|
[Photoshop Script] Layer Iterator (0) | 2012.12.12 |
C# json-for-dotnet 라이브러리 사용 (0) | 2012.12.03 |
[C++] Switch 문에서 case에 둘 변수에서 조심해야할 점 (0) | 2012.10.27 |
[Django] 시작 전 MySQL 설치에서 겪은 에러 (1) | 2012.09.16 |
- Total
- Today
- Yesterday