View Single Post
Old 05-16-2019, 09:39 AM   #15
nofish
Human being with feelings
 
nofish's Avatar
 
Join Date: Oct 2007
Location: home is where the heart is
Posts: 9,502
Default

Quote:
v5.977+dev0509 - May 9 2019
+ API: skip hidden automatic edge attachment points when counting/getting/setting points in automation items
Maybe this broke (or got changed?) in this version?

dev0509 (correct imo):


same project in dev0515:


(Attach to underlying env. on both sides enabled + loop enabled, shows one loop iteration)

Code:
function msg(m)
  return reaper.ShowConsoleMsg(tostring(m) .. "\n")
end

track = reaper.GetTrack(0,0)
env =  reaper.GetTrackEnvelope( track, 0 )

ptCnt_underlEnv = reaper.CountEnvelopePointsEx(env, -1)
ptCnt_AI1 = reaper.CountEnvelopePointsEx(env, 0)

pointsTotal = ptCnt_underlEnv + ptCnt_AI1

reaper.ClearConsole()

msg("Points in underlEnv: " .. ptCnt_underlEnv)
msg("Points in AI1: " .. ptCnt_AI1)
msg("points total: " .. pointsTotal)
edit:
To clarify, I'm wondering about point count in underl. env., point count in AI seems ok.
Maybe the phantom points came back?

Last edited by nofish; 05-16-2019 at 09:48 AM.
nofish is offline   Reply With Quote