Help with your scripting

Audio - Possible to start Playback from a specific Time?

Audio - Possible to start Playback from a specific Time?

Postby Shando » 19 Mar 2022, 05:35

Hi all,

Just wondering if there are any commands to allow 'jumping around' in an audio file?

For example, I would like to be able to do the following:

1. Forward 10 secs on the press of a button
2. Rewind 10 secs on the press of a button
3. Jump to a specific time in the audio track on the press of a button

I'm trying to create a simple music player as part of a music game I'm trying to put together and would like to provide the player with the ability to change the current playback point of the file.

Thanks

Shando

PS: Yes, I know, yet another game I've started :) This is a fairly simple one where the player runs around collecting the Stems of a song and then has to put the Stems against the correct song. I've wanted to do this for years, but could never find software that would allow me to extract the Stems from normal mp3s and still get them to sound ok :( A few weeks ago I came across RipX https://hitnmix.com/ that actually does a pretty decent job (even on live recordings!) in splitting songs into Bass, Drums, Vocals and 'everything else' (guitars, keyboards, harmonica etc.). Obviously not something I could release without permission from all the rights holders, but a fun project nonetheless :mrgreen:
Ryzen 7 4800H 16GB GTX1650 Win 11 64
Love, Hope, Strength http://www.lovehopestrength.co.uk
User avatar
Shando
Skyline Moderator
Skyline Moderator
 
Posts: 560
Joined: 06 Mar 2013, 22:35
Location: Moffat Beach, Queensland
Skill: Programmer
Skill: Scripter
Skill: Level Designer

Re: Audio - Possible to start Playback from a specific Time?

Postby SolarPortal » 19 Mar 2022, 18:43

yeah, i see what your saying, i honestly thought the audio had that in :P
Apparently not and ill add that to my list :)

Also cool idea!
Skyline Game Engine - Lead Dev.
Please provide as much info as possible when asking for help.


Specs: OS: Win 10 64bit, CPU: Intel i7 4770 3.4ghz x 4 core(8 threads), GPU: Nvidia GTX 1060 6GB, Ram: 16gig DDR3, Windows on 250gb Samsung Evo 860

Twitter: @SolarPortal
Instagram: @SolarPortal
User avatar
SolarPortal
Skyline Founder
Skyline Founder
 
Posts: 3631
Joined: 29 Jul 2012, 15:56
Location: UK
Skill: 3D Modeller
Skill: 2D Artist
Skill: Programmer
Skill: Level Designer


Return to Lua Scripting

Who is online

Users browsing this forum: No registered users and 10 guests

cron