Skip to content

Commit

Permalink
Merge pull request #308 from aeschweik/dropped-frames-again
Browse files Browse the repository at this point in the history
Dropped frames test: correct framerate
  • Loading branch information
dericed authored Apr 23, 2018
2 parents 0806235 + 366b59c commit a3063dc
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions vrecord
Original file line number Diff line number Diff line change
Expand Up @@ -582,13 +582,15 @@ _lookup_standard(){
case "${1}" in
"NTSC")
STANDARD="ntsc"
DECKLINK_FPS="30000/1001"
RECORDINGFILTER="setfield=bff,setsar=40/27,setdar=4/3"
MIDDLEOPTIONS+=(-color_primaries smpte170m)
MIDDLEOPTIONS+=(-color_trc bt709)
MIDDLEOPTIONS+=(-colorspace smpte170m)
;;
"PAL")
STANDARD="pal "
DECKLINK_FPS="25000/1000"
RECORDINGFILTER="setfield=tff,setsar=16/15,setdar=4/3"
MIDDLEOPTIONS+=(-color_primaries bt470bg)
MIDDLEOPTIONS+=(-color_trc bt709)
Expand All @@ -608,8 +610,7 @@ _yes_or_no(){
}

_frames_to_hhmmss(){
FRAMERATE=$(grep "fps=" "${LOGDIR}/${ID}${CAPTURELOGSUFFIX}" | cut -d' ' -f 5)
NUM=$(bc <<< "scale=0; ${i} / ${FRAMERATE}")
NUM=$(bc <<< "scale=0; ${i} / (${DECKLINK_FPS})")
printf "%02d:%02d:%02d\n" $(($NUM/3600)) $(($NUM%3600/60)) $(($NUM%60))
}

Expand Down

0 comments on commit a3063dc

Please sign in to comment.