Go Back   Cockos Incorporated Forums > REAPER Forums > REAPER Bug Reports

Reply
 
Thread Tools Display Modes
Old 10-04-2014, 04:32 AM   #1
lossius
Human being with feelings
 
Join Date: Jul 2011
Location: Bergen, Norway
Posts: 85
Default JS plugin automation data generated by GUI is not always properly recorded (FIXED)

Unless I'm doing something wrong when developing JS plugins, I believe that there is an issue when recording automation data from JS plugins with a GUI:

If you set a track to "Touch" track automation mode, and then interact with JS plugin parameters via a custom GUI, the plugin parameters are not automatically added to the list of parameters to record automation data for, and hence the automation data is not being recorded as supposed to.

Here are steps to reproduce:

1) Copy the following code into a new JSFX plugin (and call it e.g. automationtest):

https://gist.github.com/lossius/82dd259a50c35f304148

2) Create a Reaper project with a stereo track, and add a stereo sound file onto this track.

3) Add the "automationtest" plugin to the track.

4) Set the track to use "Touch" track automation mode.

5) Start playing from the start, and move the red circle in the plugin gui (you need to click and drag in the GUI to move it).

Result: The 2 sliders in the plugin moves, but automation is being recorded.

6) Start playing from the start again, and touch each of the sliders displayed above the gui.

Result: Automation is registered.

7) Now play from the start again, and move the circle about.

Result: Now automation data is being recorded as expected.

NOTE: This issue is not only affecting the Touch Track Automation Mode, the same thing happens with Latch and Write modes.
lossius is offline   Reply With Quote
Old 10-20-2014, 05:25 AM   #2
DarkStar
Human being with feelings
 
DarkStar's Avatar
 
Join Date: May 2006
Location: Surrey, UK
Posts: 16,596
Default

Confirmed in a completely different JS FX (using Automation "Write" mode):
-- dragging a JS FX slider directly is written as Automation Envelope points,
-- changing a JS FX Graphics element linked to a slider changes the slider but the changes are NOT written as Automation Envelope points.

--------------------------------
PS @ lossius, it would be better to attach the JS FX code here. I do not recognise the web site in your link (that is probably my ignorance) so I will not download from there.
__________________
DarkStar ... interesting, if true. Inspired by ...

My top 40 FRs, as voted by you (updated for August 2016)
DarkStar is offline   Reply With Quote
Old 10-20-2014, 06:50 AM   #3
lossius
Human being with feelings
 
Join Date: Jul 2011
Location: Bergen, Norway
Posts: 85
Default

@DarkStar

The code is pasted in below. Apart from that gist.github.com is commonly used to share code examples in order not to bloat the forum posts themselves with long sections of code.

Cheers,
Trond

Code:
desc: Automation test
 
slider1:0<-1,1,0.001>x
slider2:0<-1,1,0.001>y
 
in_pin:1
in_pin:2
 
out_pin:1
out_pin:2
 
/********************************************************************
Graphics
********************************************************************/
@gfx 500 500
 
// Determine geometry
gCenterX = gfx_w * 0.5;
gCenterY = gfx_h * 0.5;
 
// Update sliders when mouse is pressed
(mouse_cap == 1) ? (
  
  slider1 =  (mouse_x - gCenterX) / gCenterX;
  slider2 = -(mouse_y - gCenterY) / gCenterY;
  
  slider_automate(slider1);
  slider_automate(slider2);
);
 
// Draw circle
 
gfx_a = 1.;
gfx_r = 0.8;
gfx_g = 0.2;
gfx_b = 0.2;
  
gfx_circle((slider1 + 1)*gCenterX, (-slider2+1)*gCenterY, 10, 1, 1);
 
 
/********************************************************************
Samples are just passed through
********************************************************************/
@sample
 
spl0 = spl0;
spl1 = spl1;
lossius is offline   Reply With Quote
Old 11-16-2014, 02:43 AM   #4
lossius
Human being with feelings
 
Join Date: Jul 2011
Location: Bergen, Norway
Posts: 85
Default Fixed!

This is fixed in Reaper 4.75. Thanks a lot!
lossius is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 06:01 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2017, vBulletin Solutions Inc.