Old 02-19-2018, 11:50 AM   #1
spk77
Human being with feelings
 
Join Date: Aug 2012
Location: Finland
Posts: 2,668
Default Lua: Track tags (show and hide track groups)

Edit: About storing and restoring the script state...there is a bug/oversight in reaper: project (id) is freed from memory before script runs its atexit() function.
  • The script has to be closed first (from its main menu or by closing the script window)
  • Then the project has to be saved
  • Finally reaper can be closed




Here's a preview of a script I've been working on:
(This is an old version - see latest posts for new versions)




...and here's a video of Tracktion 6 track tags:

Last edited by spk77; 01-05-2020 at 06:16 AM.
spk77 is offline   Reply With Quote
Old 05-14-2018, 11:44 PM   #2
Kiteflyer
Human being with feelings
 
Join Date: Mar 2018
Posts: 2
Default

Not sure if I'm missing something obvious here, but, how do I add tracks to an existing tag (button)? If I select a track\s that I want to add to a tag, I only seem to have the option of creating a new tag. If this is not possible then surely it must be on the TODO list.

Apart from that, GREAT SCRIPT spk77!!!
Kiteflyer is offline   Reply With Quote
Old 05-15-2018, 09:24 PM   #3
Klangfarben
Human being with feelings
 
Join Date: Jul 2016
Location: Los Angeles, CA
Posts: 1,701
Default

Really love this script. I also think being able to modify tracks in an existing tag, especially tracks that are added after the fact would be very useful.

I would also suggest a couple more additions although these aren't deal breakers by any means.

1) Being able to change the order of the tags in the list. You have to get a bit creative with the naming right now to have tags show up in the order you want. I think hopi and bFooz suggested this as well.

2) Right now, when you click on a new tag, the previous selected tags are still selected. It would be useful to have an option to de-select previous tags when clicking on a new tag. For example, if I click on a tag, it would automatically de-select all other tags, and when I did a shift click it would add the newly clicked tag to the previously selected tags. Similar to bFooz's suggestion re: solo/mute but without the soloing/muting.

3) Right now all the deselected tags are grey. It would be great to be able to set the default unselected tag to a different color. That way I could match the track colors in my template. So for example, all the strings tags blue, all the brass red, etc. bFooz made a similar suggestion matching folder colors.

4) In terms of the layout selections, it would be extremely useful to be able to change the size of the tags. So if I take the track tags and put it on a docker or its own window I can set it to fill the entire space. Right now, the tags are pretty small so using it on a touchscreen is difficult. If I could change the size of the track tags, I could put it on a touchscreen and Bob's your uncle.

Still trying to get my head around linking a tag to a midi cc to turn on/off. No luck so far but I'll keep trying.

Thank you so much again for this amazing script. It really is brilliant.

Last edited by Klangfarben; 05-15-2018 at 09:44 PM.
Klangfarben is offline   Reply With Quote
Old 09-15-2018, 06:49 AM   #4
SergeiSobchenko
Human being with feelings
 
Join Date: Feb 2018
Location: Ukraine
Posts: 196
Default

Quote:
Originally Posted by Klangfarben View Post
Really love this script.

1) Being able to change the order of the tags in the list.

Thank you so much again for this amazing script. It really is brilliant.
It would be great!!! +1
SergeiSobchenko is offline   Reply With Quote
Old 09-04-2019, 06:03 AM   #5
todoublez
Human being with feelings
 
todoublez's Avatar
 
Join Date: Aug 2019
Location: beijing
Posts: 612
Default

omg this script is cool alrdy...
can‘t live without it for sure !

it can be cooler if it has
solo / mute function
if possible
todoublez is offline   Reply With Quote
Old 09-04-2019, 07:16 AM   #6
Tobbe
Human being with feelings
 
Tobbe's Avatar
 
Join Date: Sep 2009
Location: Northern Lights
Posts: 750
Default

Never mind. Found the theme in Reapack.

Thanks!

-----------------------------------------------------------------------------------

How did you get the tracklabel in a different fontcolors, showing in the first post.

Love Track Tags, thumbs up!
__________________
OS: Manjaro KDE Plasma, Reaper For Linux (64Bit) native linux-vst plugins, LSP-Plugins, TpL-Plugins, Harrison's AVA & VST Plugins. Behringer U-PHORIA UMC22.

Last edited by Tobbe; 09-04-2019 at 08:41 AM.
Tobbe is offline   Reply With Quote
Old 11-11-2019, 03:17 PM   #7
todoublez
Human being with feelings
 
todoublez's Avatar
 
Join Date: Aug 2019
Location: beijing
Posts: 612
Default

Thank u ,looking forward to yo next version !
Cheers !!
todoublez is offline   Reply With Quote
Old 11-24-2019, 02:40 PM   #8
spk77
Human being with feelings
 
Join Date: Aug 2012
Location: Finland
Posts: 2,668
Default

A complete overhaul of the GUI/mouse code is almost done.

"Drag and drop to dock" feature will be added:
spk77 is offline   Reply With Quote
Old 11-25-2019, 07:00 AM   #9
tompad
Human being with feelings
 
Join Date: Jan 2010
Location: Fjugesta, Sweden
Posts: 813
Default

NIIIIIIIIICE!!
__________________
ToDoList Obliques MusicMath Donation Some of mine and my friends music projects on Spotify
tompad is offline   Reply With Quote
Old 11-26-2019, 01:34 PM   #10
spk77
Human being with feelings
 
Join Date: Aug 2012
Location: Finland
Posts: 2,668
Default

Updated:
Code:
ReaTeam Scripts/Various/Track Tags (based on Tracktion 6 track tags) [v0.3.0 -> v0.3.1]
v0.3.1 by spk77 – November 26 2019
  - A complete overhaul of the mouse/GUI code (still WIP)
  - Space bar: run action "Transport: Play/stop"
  - Left click (on the GUI) and drag to move the script window
  - Drag and drop to dock (Positions: left, top left, top right and right)
  - Double click on the GUI to (temporarily) show all tracks
  - Restore focus back to REAPER on mouse button release (TCP, arrange view or selected envelope)
(This new quick docking system probably won't be working for everyone, but I wanted to include it anyway...)
spk77 is offline   Reply With Quote
Old 11-26-2019, 10:45 PM   #11
todoublez
Human being with feelings
 
todoublez's Avatar
 
Join Date: Aug 2019
Location: beijing
Posts: 612
Default

Quote:
Originally Posted by spk77 View Post
Updated:
Code:
ReaTeam Scripts/Various/Track Tags (based on Tracktion 6 track tags) [v0.3.0 -> v0.3.1]
v0.3.1 by spk77 – November 26 2019
  - A complete overhaul of the mouse/GUI code (still WIP)
  - Space bar: run action "Transport: Play/stop"
  - Left click (on the GUI) and drag to move the script window
  - Drag and drop to dock (Positions: left, top left, top right and right)
  - Double click on the GUI to (temporarily) show all tracks
  - Restore focus back to REAPER on mouse button release (TCP, arrange view or selected envelope)
(This new quick docking system probably won't be working for everyone, but I wanted to include it anyway...)
very nice!
is it on ReaPack alrdy?
todoublez is offline   Reply With Quote
Old 02-19-2018, 02:54 PM   #12
Klangfarben
Human being with feelings
 
Join Date: Jul 2016
Location: Los Angeles, CA
Posts: 1,701
Default

This is really fantastic! Would there be any way to assign a key command or MIDI CC to enable/disable specific tags/groups?
Klangfarben is offline   Reply With Quote
Old 02-20-2018, 02:43 AM   #13
Sexan
Human being with feelings
 
Sexan's Avatar
 
Join Date: Jun 2009
Location: Croatia
Posts: 4,691
Default

Awesome!!!
Sexan is offline   Reply With Quote
Old 02-20-2018, 02:48 AM   #14
SoulOne82
Human being with feelings
 
SoulOne82's Avatar
 
Join Date: Sep 2008
Location: Illville - Germany
Posts: 972
Default

Holy cow!

Assigning tags from all folder parent tracks at once is a stroke of genius.
SoulOne82 is offline   Reply With Quote
Old 02-20-2018, 03:42 AM   #15
lachinhan
Human being with feelings
 
lachinhan's Avatar
 
Join Date: Nov 2014
Location: Can Tho - Viet Nam
Posts: 305
Default Hi Spk77

Where can I find this script? It's great and useful. Thank you
__________________
NK Recording Studio
Email: lachinhan@gmail.com or admin@thuamninhkieu.com
Website:nkpro.top and ntmusicpro.com
lachinhan is offline   Reply With Quote
Old 02-20-2018, 07:48 AM   #16
vitalker
Human being with feelings
 
vitalker's Avatar
 
Join Date: Dec 2012
Posts: 13,336
Default

Perfect!
vitalker is offline   Reply With Quote
Old 02-20-2018, 01:13 PM   #17
spk77
Human being with feelings
 
Join Date: Aug 2012
Location: Finland
Posts: 2,668
Default

Thanks!
There's an alpha version available in post#1.
  • Right click on script window: shows the main menu
  • Right click on button: remove or rename button


Quote:
Originally Posted by Klangfarben View Post
This is really fantastic! Would there be any way to assign a key command or MIDI CC to enable/disable specific tags/groups?
I'm not sure...maybe that would be possible with reaper.get_action_context:

Code:
Lua: reaper.get_action_context()

is_new_value,filename,sectionID,cmdID,mode,resolution,val = reaper.get_action_context()
Returns contextual information about the script, typically MIDI/OSC input values.

val will be set to a relative or absolute value depending on mode (=0: absolute mode, >0: relative modes). resolution=127 for 7-bit resolution, =16383 for 14-bit resolution.
Notes: sectionID, and cmdID will be set to -1 if the script is not part of the action list. mode, resolution and val will be set to -1 if the script was not triggered via MIDI/OSC.
spk77 is offline   Reply With Quote
Old 02-20-2018, 03:30 PM   #18
Sexan
Human being with feelings
 
Sexan's Avatar
 
Join Date: Jun 2009
Location: Croatia
Posts: 4,691
Default

Omg, I won't even use reaper without this....
Bugs or not implemented yet:
1. You can add same folders again and again, maybe some check to only add new ones?

FR:

can it vertically align little sooner?
Sexan is offline   Reply With Quote
Old 02-21-2018, 03:15 AM   #19
DynamicK
Human being with feelings
 
Join Date: Nov 2017
Location: Gloucestershire, UK
Posts: 223
Default

Very useful...thanks for your work.
DynamicK is offline   Reply With Quote
Old 02-21-2018, 08:25 AM   #20
azimuth
Human being with feelings
 
azimuth's Avatar
 
Join Date: Apr 2014
Location: The place that's round on the ends and high in the middle
Posts: 247
Default

Nice script spk77, great idea.
azimuth is offline   Reply With Quote
Old 02-22-2018, 08:10 AM   #21
spk77
Human being with feelings
 
Join Date: Aug 2012
Location: Finland
Posts: 2,668
Default

Glad to see some interest here, thanks!
Quote:
Originally Posted by Sexan View Post
Omg, I won't even use reaper without this....
Bugs or not implemented yet:
1. You can add same folders again and again, maybe some check to only add new ones?
That's a good suggestion. Also, new tracks that are added to a tagged folder should stay visible.
(I don't know what should happen when user changes folder state from "parent" to something else )


Quote:
Originally Posted by Sexan View Post
FR:

can it vertically align little sooner?
I'll add some layout options.



This script doesn't work correctly with non-English language packs (I assume). The buttons and REAPER's TCP/MCP are updated when the script "sees" certain words in last undo point name:

Code:
  local proj_change_count = GetProjectStateChangeCount(0)
  if proj_change_count > last_proj_change_count then
    local last_action = reaper.Undo_CanUndo2(0)
    -- try to catch changes in track list
    if last_action:find("track") and not last_action:find("selection") then
      on_track_list_change(last_action)
    end
    last_proj_change_count = proj_change_count
  end
spk77 is offline   Reply With Quote
Old 02-22-2018, 10:18 AM   #22
bFooz
Human being with feelings
 
Join Date: Jul 2010
Location: Slovakia
Posts: 2,588
Default

Hi, this seem really useful! Here are my thougths:

- it should remember the last docker it was attached in. Also I think the first run should be in a floating window

- somehow incorporate folder colors. Maybe BG of a button in a track color and when the tag is selected, put a yellow(confirugable) border around it

- click into the empty area should unselect/show all tracks

- tags should be remembered on a project level

- tag ordering options - like in a project / alphabetically / user order by dragging? (remembered and freely switchable to other options)

- options - show only tagged tracks, select only tagged tracks, maybe expand only tagged folders/compress others

- UI-wise - center buttons horizontally, center buttons vertically

- on creating new tag from track selection, pop up name dialog

- focus should not stay on the script window (now when unselecting all tags, it stays). Maybe also when the mouse is moved out of the boundaries of the window switch focus to tracks. I want to play/pause any time.

-switchable horizontal/vertical ordering (e.g. I want them all in a collumn all the time in a floating window)
bFooz 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 04:37 PM.


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