How to assign Track-Insert transition through command?

You have a question or need an advice about how to do something? Ask it here!
Post Reply
end0re
Posts: 7
Joined: 06 Apr 2023 16:00
How to assign Track-Insert transition through command?

Post by end0re »

Hello, I looked through all the commands in the pdf and tried to find a command that allows me to assign Track-Insert transition to specific track, but I'm probably blind because I didn't find one :(

e.g. Through UI I can right click on a track -> Track Settings -> Special Element -> Insert Transition and set the Track-Insert transition and attenuation for that specific track, but how to do this through TCP command?

Thank you
User avatar
radio42
Site Admin
Posts: 8295
Joined: 05 Apr 2012 16:26
Location: Hamburg, Germany
Contact:
Re: How to assign Track-Insert transition through command?

Post by radio42 »

You are not bling (luckily).
Track-Insert-Transitions can not be assigned programmatically via control-commands dynamically at run-time in real-time.

What is your use case? Ie. I don’t see any need for providing such a control-command. Maybe there are other ways to achieve what you try to do…
end0re
Posts: 7
Joined: 06 Apr 2023 16:00
Re: How to assign Track-Insert transition through command?

Post by end0re »

> What is your use case?

I'm playing around right now, but basically the idea is to generate an audio file using TTS that says the current time and local weather and then I add it to playlist through TCP
Of course the current time might be a little off, but if I time it right then should be pretty accurate

> You are not bling (luckily).

Haha, that's good to know :D
I found an alternative way - if I create a new .pfp and then load track(s) from that playlist using PLS_CURRENT_APPEND_PLAYLIST then a whole new world of possibilities opens up (yay)

Thank you
end0re
Posts: 7
Joined: 06 Apr 2023 16:00
Re: How to assign Track-Insert transition through command?

Post by end0re »

> Maybe there are other ways to achieve what you try to do…

Are there more ways to do this? I guess I should improve the timing of what time the TTS says with the exact track after which the TTS file will be played (is there a command to get the end time of specific track? Then I can use that track end time as the "current time" that the TTS says)

EDIT: I see there is PLS_CURRENT_GET_ENTRY so it means I can calculate track end time by doing (schedule + playtime) right?
User avatar
radio42
Site Admin
Posts: 8295
Joined: 05 Apr 2012 16:26
Location: Hamburg, Germany
Contact:
Re: How to assign Track-Insert transition through command?

Post by radio42 »

is there a command to get the end time of specific track?
Yes, that might exactly be the way. PLS_CURRENT_GET_ENTRY actually returns most information about the referenced track.
(player|#|filename|trackname|duration|playtime|schedule|status|elapsedtime|remaintime|album|year|genre|ramp|outro)
You need to parse and extract the info though, which you need...i.e. coding is required on your side.
But I guess you need to do this anyhow for your TTS ;-)

Post Reply