Question / Help Replays On Mac

Hey!

I am searching for a way to have a similar tool like the Buffer Replay that exist in the OBS Classic.
I own a Mac so I need to find a way to have a similar tool on OBS Studio. Can anyone help me os this?

Ps: Please add Buffer Replay to OBS Studio soon, Many Thanks =)

Obrigado
 

Paddel

New Member
Hi Go Live Portugal!

To create replays on my mac I wrote a little bash script (quite dirty, but working :D) - maybe it helps you:


Code:
#!/bin/bash

CUTOUT_LENGTH=6
DELAY=2
SPEED=1

STREAM_FOLDER=/Users/paddel/Movies/OBS_Streams
REPLAY_FOLDER=/Users/paddel/Movies/replay

########

CURRENT_TIME=$(date "+%Y-%m-%d_%H-%M-%S")

osascript -e 'display notification "Creating replay ..." with title "Replay"'

sleep $DELAY

cd $STREAM_FOLDER/
LATEST="$(ls -t | head -n1)"
REPLAYEND="$(/usr/local/bin/ffprobe -i "$LATEST" -show_format | grep duration)"
REPLAYEND=${REPLAYEND:9}
REPLAYEND="$(echo $REPLAYEND | bc)"
REPLAYSTART="$(echo $REPLAYEND - $CUTOUT_LENGTH | bc)"

rm -f $REPLAY_FOLDER/replay.flv
/usr/local/bin/ffmpeg -y -ss $REPLAYSTART -i "$LATEST" -t $CUTOUT_LENGTH -c:v copy -c:a copy $REPLAY_FOLDER/replay_.flv
/usr/local/bin/ffmpeg -y -i $REPLAY_FOLDER/replay_.flv -filter_complex "setpts=1/$SPEED*PTS" -an -q:v 0 $REPLAY_FOLDER/replay.flv
osascript -e 'display notification "Replay created!" with title "Replay"'

ARCHIVE_FILE=$REPLAY_FOLDER/archive/$CURRENT_TIME\_Replay.flv
cp $REPLAY_FOLDER/replay.flv $ARCHIVE_FILE
 
Top