|
|
|
02-17-2019, 11:46 AM
|
#361
|
Human being with feelings
Join Date: Jun 2009
Location: Croatia
Posts: 24,798
|
Whoa, docking above ruler! Nice!
A couple of things:
1. When I dock it, the text isn't antialiased as the ruler text is. Not sure why would that happen?
2. fontFace variable should probably say "Arial" not "Ariel" (I've seen this typo in your other scripts, too.)
3. Dock state doesn't seem to be remembered? If I run the script, dock it, end the script, then run it again, it starts undocked. It should remember the dock state, probably?
|
|
|
02-17-2019, 12:21 PM
|
#362
|
Human being with feelings
Join Date: Jul 2009
Posts: 3,714
|
Quote:
Originally Posted by Vagelis
|
Ah, thanks for sending the detailed error message. Please check that ReaPack has updated the scripts to v4.02. In v4.02, "insertValue" doesn't occur on line 514.
|
|
|
02-17-2019, 12:22 PM
|
#363
|
Human being with feelings
Join Date: Jul 2009
Posts: 3,714
|
Quote:
Originally Posted by lunker
Yeah, I vote for that. That would enable creating "strum" chords with this tool. (although there are plenty of other ways to do that in Reaper already)
|
As Stevie mentioned, the Arpeggiate mouse modifier action will probably be more useful for creating strums, since it can warp the note positions into natural shapes, whereas the Slice script just slices in a straight line or on the grid. (I might add some mousewheel control of the line curve in the future...)
|
|
|
02-17-2019, 12:28 PM
|
#364
|
Human being with feelings
Join Date: Oct 2017
Location: Black Forest
Posts: 5,067
|
Not if you turn off the snap
|
|
|
02-17-2019, 02:39 PM
|
#365
|
Human being with feelings
Join Date: Oct 2017
Location: Larisa, Greece
Posts: 3,827
|
Quote:
Originally Posted by juliansader
Ah, thanks for sending the detailed error message. Please check that ReaPack has updated the scripts to v4.02. In v4.02, "insertValue" doesn't occur on line 514.
|
Yes, now it works perfect!
|
|
|
02-17-2019, 04:47 PM
|
#366
|
Human being with feelings
Join Date: Nov 2006
Posts: 858
|
Hi Julian,
These look amazing! I don't suppose you would be able to export your toolbar of midi fun for us to import?
Thanks
|
|
|
02-21-2019, 08:16 AM
|
#367
|
Human being with feelings
Join Date: Jun 2012
Posts: 348
|
Can I chain together 2 scripts?
I have a keyboard shortcut set up for "js_Mouse editing - Draw ramp" and another for "js_Remove redundant CCs (from selected events in lane under mouse)" but I would like to always run them together. I tried creating a custom action but the result is that when I press the key to run my custom combined action, I don't get a ramp or a curve, I get a single CC event.
Ideally I like to see "js_Mouse editing - Draw ramp" draw all redundant CC events until the script terminates then automatically remove the redundant CC messages, but failing that, I'd at least like to find a way to chain those two things together. Is it possible?
Note: I'm using the latest Reaper, SWS extension and js_ scripts.
|
|
|
02-21-2019, 12:49 PM
|
#368
|
Human being with feelings
Join Date: Jul 2009
Posts: 3,714
|
Quote:
Originally Posted by todd_r
These look amazing! I don't suppose you would be able to export your toolbar of midi fun for us to import?
|
Hehe, my toolbar is currently a big mess. Because I've been writing a lot of new scripts, my toolbar is full of buttons that I used for testing purposes, as well as buttons that refer to outdated scripts.
(BTW, even though my "Mouse editing" scripts can be used from the toolbar, via "toolbar arming", I personally prefer using keyboard shortcuts, so my usual toolbar (when it's cleaned up) don't include these.)
|
|
|
02-21-2019, 03:33 PM
|
#369
|
Human being with feelings
Join Date: Jun 2009
Location: Croatia
Posts: 24,798
|
Any comments on the points I've made, Julian?
|
|
|
02-21-2019, 03:49 PM
|
#370
|
Human being with feelings
Join Date: Jul 2009
Posts: 3,714
|
Quote:
Originally Posted by EvilDragon
1. When I dock it, the text isn't antialiased as the ruler text is. Not sure why would that happen?
|
The text is rendered via GDI, separate from REAPER's own graphics. The GDI font is set to "ANTIALIASED_QUALITY", so I'm not sure why it isn't properly antialiased. "PROOF_QUALITY", which is supposed to be the best quality, looks worse.
Quote:
Originally Posted by EvilDragon
2. fontFace variable should probably say "Arial" not "Ariel" (I've seen this typo in your other scripts, too.)
|
Whoops! Will correct.
Quote:
Originally Posted by EvilDragon
3. Dock state doesn't seem to be remembered? If I run the script, dock it, end the script, then run it again, it starts undocked. It should remember the dock state, probably?
|
Will implement this soon, in next update.
|
|
|
02-21-2019, 04:14 PM
|
#371
|
Human being with feelings
Join Date: Jul 2009
Posts: 3,714
|
Quote:
Originally Posted by pbattersby
I have a keyboard shortcut set up for "js_Mouse editing - Draw ramp" and another for "js_Remove redundant CCs (from selected events in lane under mouse)" but I would like to always run them together. I tried creating a custom action but the result is that when I press the key to run my custom combined action, I don't get a ramp or a curve, I get a single CC event.
|
Continuous scripts, such as the Mouse editing ones, can unfortunately not be combined into custom actions, except as the very last action, because any subsequent actions will be executed while the continuous script is still running.
Quote:
Originally Posted by pbattersby
Ideally I like to see "js_Mouse editing - Draw ramp" draw all redundant CC events until the script terminates then automatically remove the redundant CC messages, but failing that, I'd at least like to find a way to chain those two things together. Is it possible?
|
Possible solutions:
* Assign Remove Redundant CCs to the "R" shortcut, right beneath your left index finger, so it is very easy to run it whenever necessary.
* The Draw ramp and Draw LFO scripts continually check whether the "Skip redundant events" option is enabled, so if you assign this option to a keyboard shortcut (without a modifier key), you can toggle it while the script is running. (Hmmm, I just noticed that you have to move the mouse or click a button after toggling the option, else the script doesn't notice that something has changed -- I will improve this in a next version.)
* Edit the script, so that it calls Remove Redundant CCs when it terminates. To do this:
1) Get the command ID of the appropriate Remove Redundant CCs script. (Right-click on it in the Actions list.) It should be a long string of letters and numbers.
2) Open the script in the IDE, find the AtExit function, and add this line to the very end (replace "command ID" with the string that you copied, inside quotation marks:
Code:
if editor then reaper.MIDIEditor_OnCommand(editor, reaper.NamedCommandLookup("command ID")) end
|
|
|
02-21-2019, 04:19 PM
|
#372
|
Human being with feelings
Join Date: Jun 2009
Location: Croatia
Posts: 24,798
|
Quote:
Originally Posted by juliansader
The text is rendered via GDI, separate from REAPER's own graphics. The GDI font is set to "ANTIALIASED_QUALITY", so I'm not sure why it isn't properly antialiased. "PROOF_QUALITY", which is supposed to be the best quality, looks worse.
|
Not sure, I'd expect it to look the same as the ruler font does. It's obvious that antialiasing isn't used at all on the inspector
Regarding other points - thanks! Will await eagerly for the next updates
|
|
|
02-21-2019, 06:09 PM
|
#373
|
Human being with feelings
Join Date: Jun 2012
Posts: 348
|
Quote:
Originally Posted by juliansader
* Assign Remove Redundant CCs to the "R" shortcut, right beneath your left index finger, so it is very easy to run it whenever necessary.
|
Yes, I've been doing that. Not a bad way to deal with it.
Quote:
Originally Posted by juliansader
* Edit the script, so that it calls Remove Redundant CCs when it terminates.
|
Thanks for explaining that. I'll give it a try but is there any chance you can be convinced to make that default behaviour or at least the behaviour when
Code:
[js_Mouse actions]
skipRedundantCCs=true
[LFO generator]
skipRedundantCCs=true
... is set in reaper-exstate.ini? I find your script works best when redundant CC values appear while drawing a curve but then redundant CC values disappear when the script terminates. With your explanation I can make it work that way myself but I think it would be beneficial if it worked that way by default. Just a friendly suggestion.
|
|
|
02-23-2019, 04:14 PM
|
#374
|
Human being with feelings
Join Date: Jun 2018
Location: Vienna
Posts: 17
|
I've read already several time how to set some of these scripts but no success...looking for a tiny clue!
I've set both the 1 and 2-sided warps as toolbar buttons and added a shortcut to the "Run script...".
I arm (left click) the "1-side Warp" button then move towards the already selected notes,
hit the shortcut and if I move the mouse nothing happens and if I click obviously I deselect everything.
The script only works if I hold down the shortcut (which causes the mouse to flicker) and left drag.
The 2-sided script is even weirder: I click the shortcut (after arming) and I get this error message:
This script will only work in the following MIDI lanes:
* 7-bit CC,
* 14-bit CC,
* Velocity,
* Channel Pressure,
* Pitch,
* Program select,
* Bank/Program,
* Text or Sysex,
or in the 'notes area' of the piano roll.
I'm pretty sure I am missing something very obvious!
|
|
|
02-24-2019, 08:46 AM
|
#375
|
Human being with feelings
Join Date: Jul 2009
Posts: 3,714
|
Quote:
Originally Posted by EvilDragon
Regarding other points - thanks! Will await eagerly for the next updates
|
Update uploaded!
Quote:
Originally Posted by mrmuzzi
I arm (left click) the "1-side Warp" button then move towards the already selected notes,
hit the shortcut and if I move the mouse nothing happens and if I click obviously I deselect everything.
|
Could you perhaps upload a screencap GIF to show what is happening? (Most users use Cockos's own LICEcap software to record GIFs, and the file can be uploaded to the forum's stash.)
* Did the mouse cursor change (even momentarily)? This would indicate that the script tried to run.
* Where was the mouse positioned when the script was started? (Somewhere within a CC lane? Which CC lane? Over a lane divider?)
* Was the keyboard shortcut only hit *once* to start the script, and without holding down any mouse buttons?
Quote:
Originally Posted by mrmuzzi
The script only works if I hold down the shortcut (which causes the mouse to flicker) and left drag.
|
Holding down the shortcut will unfortunately not work. With a rare few exceptions, REAPER actions (including scripts) are started and stopped by pressing the shortcut once to start, and then once to stop. (The mouse editing scripts do offer some additional options, as described on the first page.)
Quote:
Originally Posted by mrmuzzi
The 2-sided script is even weirder: I click the shortcut (after arming) and I get this error message:
|
This error message should pop up if the mouse was not positioned somewhere *within* a CC lane (or the notes area) when the script started. If the mouse is not positioned inside a CC lane, the script would not know which specific CC lane it is intended to edit. (I should probably edit that error message to give some tips on mouse positioning.)
Last edited by juliansader; 02-24-2019 at 01:29 PM.
|
|
|
02-24-2019, 02:24 PM
|
#376
|
Human being with feelings
Join Date: Jun 2018
Location: Vienna
Posts: 17
|
Hi julian and first of all thanks for your amazing job!
I wanted to set a toolbar like like in the OTR project:
https://youtu.be/klGYZFaaD2M?t=112
Here is what I get (I left click on the toolbar, no shortcut for the scripts except the A linked to the "Run" one):
Now, the editor here is docked.
If I undock it, the first script works but when I left click or hit the A again the editor greys out and if I click again REAPER crashes!
The second script behaves the same....
|
|
|
02-25-2019, 07:04 AM
|
#377
|
Human being with feelings
Join Date: Jun 2018
Location: Vienna
Posts: 17
|
And here is what happens when I undock the editor:
It greys out either with "a" or Left click, the difference is that if I don't close the editor and click a third time "a", Reaper crashes, with left click it doesn't.
|
|
|
02-25-2019, 01:26 PM
|
#378
|
Human being with feelings
Join Date: Oct 2018
Posts: 202
|
Quote:
Originally Posted by EvilDragon
Not sure, I'd expect it to look the same as the ruler font does. It's obvious that antialiasing isn't used at all on the inspector
Regarding other points - thanks! Will await eagerly for the next updates
|
uh sorry for the OT, but what is this beautiful skin?
regarding the actual topic.. these midi tools are a godsend.
|
|
|
02-26-2019, 02:40 PM
|
#379
|
Human being with feelings
Join Date: Jul 2009
Posts: 3,714
|
There appears to be two distinct problems:
Quote:
Originally Posted by mrmuzzi
Now, the editor here is docked.
If I undock it, the first script works but when I left click or hit the A again the editor greys out and if I click again REAPER crashes!
|
I think this will be fixed by the new ReaScriptAPI v0.971. Could you please update and test again?
Quote:
Originally Posted by mrmuzzi
I arm (left click) the "1-side Warp" button then move towards the already selected notes, hit the shortcut and if I move the mouse nothing happens
|
I'm not sure what strange things macOS might be doing in this case. I PM'd you a diagnostic script that would hopefully help.
|
|
|
02-26-2019, 03:03 PM
|
#381
|
Human being with feelings
Join Date: Jun 2009
Location: Croatia
Posts: 24,798
|
Julian, do you know if there's any way to run the MIDI inspector script when Reaper is started up? I have my MIDI editor always opened on second monitor (you can see the image in previous post), so I assumed writing a short script for Main context that would trigger MIDI inspector script, then placing that in SWS global startup action, would work:
Code:
active_ME = reaper.MIDIEditor_GetActive()
reaper.MIDIEditor_OnCommand(active_ME, reaper.NamedCommandLookup("_RSf0f16cbed0161f0eb6852873971c4398476054c0"))
but it doesn't...
|
|
|
02-28-2019, 06:30 AM
|
#382
|
Human being with feelings
Join Date: Jul 2009
Posts: 3,714
|
Thanks to some diagnostic test that MrMuzzi performed, I discovered something very weird -- and completely undocumented in both the API help and WDL/swell documentation.
For some functions on macOS, the pixel coordinates of the mouse cursor and of window positions are given differently than on Windows/Linux: macOS: Does GetMousePosition() return coordinates relative to *bottom* of screen?
So, for the time being, the new Mouse editing scripts will unfortunately work on macOS. It is fixable, but will take quite a bit of time.
EDIT 2019-03-04: FIXED!
Last edited by juliansader; 03-04-2019 at 04:56 PM.
|
|
|
02-28-2019, 12:18 PM
|
#383
|
Human being with feelings
Join Date: Jul 2009
Posts: 3,714
|
Quote:
Originally Posted by EvilDragon
Julian, do you know if there's any way to run the MIDI inspector script when Reaper is started up? I have my MIDI editor always opened on second monitor (you can see the image in previous post), so I assumed writing a short script for Main context that would trigger MIDI inspector script, then placing that in SWS global startup action, would work:
Code:
active_ME = reaper.MIDIEditor_GetActive()
reaper.MIDIEditor_OnCommand(active_ME, reaper.NamedCommandLookup("_RSf0f16cbed0161f0eb6852873971c4398476054c0"))
but it doesn't...
|
The newest v1.47 of the script can be started even if no editor is open yet, and does not automatically terminate when all editors are closed. It will wait in the background and reappear when an editor is opened (It uses negligible CPU when just waiting in the background.)
You can load the script into the Main section, and then it can be run during startup even before any MIDI editor is opened.
|
|
|
02-28-2019, 12:35 PM
|
#384
|
Human being with feelings
Join Date: Jun 2009
Location: Croatia
Posts: 24,798
|
Thanks!!
Now if only the font could be improved upon somehow so that it's bold if ruler is bold (or have an option in extstate.ini for that), and we have a perfect inspector
|
|
|
02-28-2019, 04:25 PM
|
#385
|
Human being with feelings
Join Date: Oct 2017
Location: Black Forest
Posts: 5,067
|
Quote:
Originally Posted by EvilDragon
Thanks!!
Now if only the font could be improved upon somehow so that it's bold if ruler is bold (or have an option in extstate.ini for that), and we have a perfect inspector
|
It's not possible to change the values in the inspector, when it's docked, right?
|
|
|
02-28-2019, 10:48 PM
|
#386
|
Human being with feelings
Join Date: Jun 2009
Location: Croatia
Posts: 24,798
|
No it's just a display AFAIK.
|
|
|
03-01-2019, 11:53 PM
|
#387
|
Human being with feelings
Join Date: Oct 2017
Location: Black Forest
Posts: 5,067
|
Julian, I have some really erratic behavior with the CC scripts.
Everytime I execute a script in the MIDI editor (CC lane) the MIDI editor loses focus and from now on, all hotkeys are forwarded to the arrange window.
I have to click in the CC lane again, to trigger the script.
Is there anything you changed in that area?
|
|
|
03-02-2019, 05:50 AM
|
#388
|
Human being with feelings
Join Date: Jul 2009
Posts: 3,714
|
Quote:
Originally Posted by _Stevie_
Everytime I execute a script in the MIDI editor (CC lane) the MIDI editor loses focus and from now on, all hotkeys are forwarded to the arrange window.
|
Thanks for letting me know. Does it only happen if the editor is docked? I quickly uploaded fixed versions.
|
|
|
03-02-2019, 11:07 AM
|
#389
|
Human being with feelings
Join Date: Oct 2017
Location: Black Forest
Posts: 5,067
|
Just to let the others know, the fix did it!
|
|
|
03-05-2019, 10:11 AM
|
#390
|
Human being with feelings
Join Date: Nov 2015
Posts: 607
|
OS:w10
ReaPack v1.2.2 built on Feb 24 2019 11:46:24
Hi, I am trying to use The "Connect nodes" script, i get the following error (I guess I am doing something wrong):
|
|
|
03-05-2019, 10:24 AM
|
#391
|
Human being with feelings
Join Date: Jul 2009
Posts: 3,714
|
Quote:
Originally Posted by Vagalume
OS:w10
ReaPack v1.2.2 built on Feb 24 2019 11:46:24
Hi, I am trying to use The "Connect nodes" script, i get the following error (I guess I am doing something wrong):
|
The "Connect nodes" script cannot be applied to notes or velocity (the two areas visible in the screenshot), since velocity cannot be changed or smoothly ramped after the note-on has already been played.
Similarly, sysex and text cannot be "connected".
(I should add a sentence regarding velocities to the error message for the next update.)
|
|
|
03-05-2019, 10:37 AM
|
#392
|
Human being with feelings
Join Date: Nov 2015
Posts: 607
|
So, it is not possible for velocity but it will be possible for expression, for example.
Edited: it works for expression, I now understand what you meant by smoothing.
Thanks for your time, Julian.
Last edited by Vagalume; 03-05-2019 at 10:46 AM.
|
|
|
03-12-2019, 10:15 AM
|
#393
|
Human being with feelings
Join Date: Jun 2009
Location: Croatia
Posts: 24,798
|
Julian, two things I noticed:
1. When the inspector is docked above transport, it seems to steal right-clicks even if you have another program on top of Reaper (in my case web browser) and shows its context menu, ALONG with the context menu of the other program.
2. When there's a lot of mousing in the MIDI editor, there's a TON of flickering in order to refresh the inspector. Maybe don't do UI refresh until mouse is released? Not sure...
|
|
|
03-15-2019, 12:19 AM
|
#394
|
Human being with feelings
Join Date: Jun 2009
Location: Croatia
Posts: 24,798
|
Just bumping this in case Julian missed the above
|
|
|
03-15-2019, 12:59 PM
|
#395
|
Human being with feelings
Join Date: Jul 2009
Posts: 3,714
|
Quote:
Originally Posted by EvilDragon
1. When the inspector is docked above transport, it seems to steal right-clicks even if you have another program on top of Reaper (in my case web browser) and shows its context menu, ALONG with the context menu of the other program.
|
Nice catch. Fixed in v1.49.
Quote:
Originally Posted by EvilDragon
2. When there's a lot of mousing in the MIDI editor, there's a TON of flickering in order to refresh the inspector. Maybe don't do UI refresh until mouse is released? Not sure...
|
Unfortunately I don't know if the flickering can be avoided. If the UI isn't refreshed, it will simply disappear, which would be worse.
|
|
|
03-16-2019, 12:25 AM
|
#396
|
Human being with feelings
Join Date: Jun 2009
Location: Croatia
Posts: 24,798
|
Ugh. It's really a problem for usability then. Flickering is annoying and tires the eyes... Not to mention the font is too tiny because it's not antialiased...
Are you saying whenever you draw something in MIDI editor (regular part of Reaper), it triggers a whole screen refresh, and if you don't do the same for the inspector, it just goes away? That is a bummer...
But wait, I can have the LFO tool (for arrange view envelopes) docked and there's no flickering when I draw anything in the arrange (new items, envelope points...). So it SHOULD be possible, no?
Is it because you're getting MIDI data on every new mouse movement/data input in MIDI editor, then refreshing the GUI with that? I guess that definitely would create flickering... but what if you only do this on mouse release?
|
|
|
03-16-2019, 02:01 PM
|
#397
|
Human being with feelings
Join Date: Jul 2009
Posts: 3,714
|
Quote:
Originally Posted by EvilDragon
Ugh. It's really a problem for usability then. Flickering is annoying and tires the eyes... Not to mention the font is too tiny because it's not antialiased...
|
Ouch, I hope it's not really that bad. It should only flicker while you are actively drawing. You can change the font size and weight in the script's user area, but the font cannot be much larger than the ruler font, otherwise it wouldn't fit.
Quote:
Originally Posted by EvilDragon
Are you saying whenever you draw something in MIDI editor (regular part of Reaper), it triggers a whole screen refresh, and if you don't do the same for the inspector, it just goes away? That is a bummer...
|
Drawing inside a script GUI uses REAPER's own gfx functions, so there is no conflict. Drawing inside other REAPER windows such as the piano toll is a bit of a hack: it uses OS functions (such as GDI on WindowsOS) to draw stuff, without REAPER even knowing about it.
I suspect the flickering is due to REAPER and the script drawing independently and alternately into the same window, each overwriting the other. On WindowsOS, in non-static windows that are continuously being refreshed, the script's GDI graphics are drawn last in each defer cycle, so the script graphics are usually visible. Unfortunately, on macOS and Linux, script graphics is drawn earlier than REAPER's, so script graphics aren't visible in non-static windows. I have tried various tricks to avoid the flicker, but without success, and Justin confirmed that it would be messy/tricky to do with existing functions.
I have submitted a FR for a native function for blitting into REAPER's windows: Extension API: Blitting into REAPER windows, for seamless integration into REAPER UI. If any users of my scripts see this link, please give a +1 to that FR!
|
|
|
03-17-2019, 03:33 AM
|
#398
|
Human being with feelings
Join Date: Jun 2009
Location: Croatia
Posts: 24,798
|
Quote:
Originally Posted by juliansader
Ouch, I hope it's not really that bad. It should only flicker while you are actively drawing. You can change the font size and weight in the script's user area, but the font cannot be much larger than the ruler font, otherwise it wouldn't fit.
|
It really is pretty bad, but more importantly, it's distracting in a bad way. I'll post a GIF later on since today I'm not at my desktop.
Font size is not that much of a problem, it's the thinness of the font - it's not antialiased like the ruler font is. Remember how MIDI editor ruler font wasn't AA'd before and it was thin and looked nothing like ruler font in arrange, until Cockos fixed that? This is exactly how it is with the inspector docked. I think I posted a screenshot already in this thread
|
|
|
03-17-2019, 09:38 AM
|
#399
|
Human being with feelings
Join Date: Oct 2017
Location: Black Forest
Posts: 5,067
|
Not to disrespect Julian's work in any way, you know, I might be one of your biggest fans
But, I really hope we finally (v6?) get this functionality natively.
A way to display and change values (pitch, velocity, position, length, etc...) in the MIDI editor.
|
|
|
03-17-2019, 10:30 AM
|
#400
|
Human being with feelings
Join Date: Jan 2017
Posts: 42
|
OMG!!! I LOVE YOU!!!
This is exactly what i was looking for in Reaper!!!
Thank you!!!
__________________
--------------------------------------------------------------
Don't have a clue what to put here.....
|
|
|
Thread Tools |
|
Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -7. The time now is 08:45 PM.
|