Go Back   Cockos Incorporated Forums > REAPER Forums > REAPER Pre-Release Discussion

Reply
 
Thread Tools Display Modes
Old 11-13-2018, 07:27 PM   #41
wwwmaze
Human being with feelings
 
Join Date: Oct 2009
Posts: 99
Default

Quote:
Originally Posted by Edgemeal View Post
v5.961+dev1027 - October 27 2018
+ Video: add input_get_name() to get input take/track name
What am I doing wrong?
Code:
input_get_name(input,name=#);
only gives me the filename of the source.

EDIT: Sry it somehow did not refresh.
So I am able to get the take name, but how do I get the track name?

Last edited by wwwmaze; 11-13-2018 at 07:46 PM.
wwwmaze is offline   Reply With Quote
Old 11-13-2018, 07:44 PM   #42
Justin
Administrator
 
Justin's Avatar
 
Join Date: Jan 2005
Location: NYC
Posts: 15,721
Default

Quote:
Originally Posted by wwwmaze View Post
What am I doing wrong?
Code:
input_get_name(input,name=#);
only gives me the filename of the source.
Need to see it in the context of the project, I guess?
Justin is offline   Reply With Quote
Old 11-13-2018, 07:45 PM   #43
Justin
Administrator
 
Justin's Avatar
 
Join Date: Jan 2005
Location: NYC
Posts: 15,721
Default

Quote:
Originally Posted by mschnell View Post
Would I e.g. be able to do something that I currently would need to use a Midi CC message and send it via MidiToReaControlPath to trigger a script that is assigned to that CC ? Maybe I now could do a "defer" script that polls a gmem location and the JSFX will set seam.
I don't understand the question, but the answer is almost certainly yes.
Justin is offline   Reply With Quote
Old 11-13-2018, 07:58 PM   #44
wwwmaze
Human being with feelings
 
Join Date: Oct 2009
Posts: 99
Default

Quote:
Originally Posted by Justin View Post
Need to see it in the context of the project, I guess?
The context would be:

Code:
parent with video processor, no video items/inputs
---child, normally exactly 1 video item/input
---child, normally exactly 1 video item/input
I was hoping to get inputs based on the names of the child tracks to be able to stack video processors:

Code:
parent b* 
---parent a* (= child b)
------child a
------child a
---child b


* has a video processor as FX
wwwmaze is offline   Reply With Quote
Old 11-13-2018, 08:34 PM   #45
Justin
Administrator
 
Justin's Avatar
 
Join Date: Jan 2005
Location: NYC
Posts: 15,721
Default

The way video processors deal with tracks/items/etc might be causing you some problems. You might need to review the help text about how to enumerate/navigate the list of video inputs, but here's a quick explanation:
  • You can't get the name of a track unless it has a video processor on it at the track level.
  • Input 0 is the first input available to the processor. This could be the previous FX in the chain, or if a track FX, it could be the previous track, or an item on the track (or a take FX on the item on the track, etc).
  • If you want to get the output of the previous track that contains a video item/processor/etc, you should query input_track(0). If you want the second track that contains one of those, use input_track(1).
  • There are other functions to navigate the inputs.
  • Remember, any item/track that doesn't have any video processors/video files is effectively ignored (except when using input_track_exact() etc).

Here's a little demo project I made for you:

https://1014.org/_/video_name_test.RPP

You can load whatever movie you want in replace of the .MOV file to test.

Track 1 "describe what is seen" has a processor which takes the first input (wherever it is), draws it, then draws the text that it gets from it over it.

At the start of the project, it reads from "item that is red", which is a MIDI item that has a video processor on it that generates red.

Then in the empty space between 2 and 3 seconds, there's no video processor on an item or the track, so instead it displays "green track", which has a video processor at the track level.

When it gets to the second item, which is a .MOV, it displays that, and uses the take name (since that take was renamed). Then between 4.5 and 5 seconds it goes back to green..

And the third item is just the same as the second item, only it has the filename of the .MOV in it (I didn't bother renaming that one). There's no way to actually get the filename, it just uses the take names.

Hope that helps!
Justin is offline   Reply With Quote
Old 11-13-2018, 10:51 PM   #46
mschnell
Human being with feelings
 
mschnell's Avatar
 
Join Date: Jun 2013
Location: Krefeld, Germany
Posts: 14,686
Default

Quote:
Originally Posted by Justin View Post
I don't understand the question, but the answer is almost certainly yes.
The goal is to use the Reaper API by something that happens in the realm of the track FX chains (e.g. Midi messages). This is one of the main discussion issues in the many "Reaper Live usage" threads running in theses forums. Doing a single (timed) Reaper script maybe would be a cleaner solution than sending Midi CC messages to the Reaper Control Path and firing a bunch of Reaper Scripts with these.

I'll do a test once this update makes it into the released version (Or do you want me to test this right now ? Is there a documentation on this ? )

-Michael

Last edited by mschnell; 11-13-2018 at 11:02 PM.
mschnell is offline   Reply With Quote
Old 11-14-2018, 02:52 PM   #47
wwwmaze
Human being with feelings
 
Join Date: Oct 2009
Posts: 99
Default

Quote:
Originally Posted by Justin View Post
The way video processors deal with tracks/items/etc might be causing you some problems. You might need to review the help text about how to enumerate/navigate the list of video inputs, but here's a quick explanation:
  • You can't get the name of a track unless it has a video processor on it at the track level.
  • Input 0 is the first input available to the processor. This could be the previous FX in the chain, or if a track FX, it could be the previous track, or an item on the track (or a take FX on the item on the track, etc).
  • If you want to get the output of the previous track that contains a video item/processor/etc, you should query input_track(0). If you want the second track that contains one of those, use input_track(1).
  • There are other functions to navigate the inputs.
  • Remember, any item/track that doesn't have any video processors/video files is effectively ignored (except when using input_track_exact() etc).

Here's a little demo project I made for you:

https://1014.org/_/video_name_test.RPP

You can load whatever movie you want in replace of the .MOV file to test.

Track 1 "describe what is seen" has a processor which takes the first input (wherever it is), draws it, then draws the text that it gets from it over it.

At the start of the project, it reads from "item that is red", which is a MIDI item that has a video processor on it that generates red.

Then in the empty space between 2 and 3 seconds, there's no video processor on an item or the track, so instead it displays "green track", which has a video processor at the track level.

When it gets to the second item, which is a .MOV, it displays that, and uses the take name (since that take was renamed). Then between 4.5 and 5 seconds it goes back to green..

And the third item is just the same as the second item, only it has the filename of the .MOV in it (I didn't bother renaming that one). There's no way to actually get the filename, it just uses the take names.

Hope that helps!
Thank you Justin. As this is probably getting too off-topic I answered here:
https://forum.cockos.com/showthread.php?t=213455
wwwmaze is offline   Reply With Quote
Old 12-07-2018, 07:36 AM   #48
TonE
Human being with feelings
 
Join Date: Feb 2009
Location: Reaper HAS send control via midi !!!
Posts: 4,031
Default

Quote:
Originally Posted by wwwmaze View Post
The context would be:

Code:
parent with video processor, no video items/inputs
---child, normally exactly 1 video item/input
---child, normally exactly 1 video item/input
I was hoping to get inputs based on the names of the child tracks to be able to stack video processors:

Code:
parent b* 
---parent a* (= child b)
------child a
------child a
---child b


* has a video processor as FX
Never thought of using folderify.lua for video, but why not?
see https://forum.cockos.com/showthread.php?t=213883
TonE is offline   Reply With Quote
Old 12-07-2018, 07:52 AM   #49
TonE
Human being with feelings
 
Join Date: Feb 2009
Location: Reaper HAS send control via midi !!!
Posts: 4,031
Default

Quote:
Originally Posted by Justin View Post


(tons of fun)
Reaper goes psychedelic.
TonE 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 05:37 AM.


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