summaryrefslogtreecommitdiff
path: root/hacks
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2025-10-06 00:14:53 +0200
committerCarl Hetherington <cth@carlh.net>2025-10-06 00:14:53 +0200
commit2adc3886077fc1c694f618ed19fbc01629548cb5 (patch)
treec3febaa371d8f83ffa5a7e67017b646b5b14791a /hacks
parent2c210c7444db13c3273645c390d2349ee2d22e2e (diff)
Specify 16-bit for dummy WAV files so they don't get too big and trip the 32-bit length limit.
Diffstat (limited to 'hacks')
-rwxr-xr-xhacks/make_dummy_files4
1 files changed, 2 insertions, 2 deletions
diff --git a/hacks/make_dummy_files b/hacks/make_dummy_files
index 21c09e2ea..5fbbf82be 100755
--- a/hacks/make_dummy_files
+++ b/hacks/make_dummy_files
@@ -109,7 +109,7 @@ for c in root.find('Playlist').findall('Content'):
channels = int(c.find('AudioMapping').find('InputChannels').text)
path = os.path.join(sys.argv[1], 'dummy', ntpath.basename(c.find('Path').text))
audio_length = int(c.find('AudioLength').text)
- os.system('sox -n -r %d -c %d %s trim 0.0 %f' % (audio_frame_rate, channels, path, float(audio_length) / audio_frame_rate))
+ os.system('sox -b 16 -n -r %d -c %d %s trim 0.0 %f' % (audio_frame_rate, channels, path, float(audio_length) / audio_frame_rate))
elif type == 'FFmpeg':
video_cmd = ''
audio_cmd = ''
@@ -130,7 +130,7 @@ for c in root.find('Playlist').findall('Content'):
elif c.find('VideoFrameRate') is not None:
command(f'ffmpeg -i video.mp4 "{path}"')
else:
- command('sox -n -r %d -c %d %s trim 0.0 %f' % (audio_frame_rate, audio_channels, path, float(audio_length) / audio_frame_rate))
+ command('sox -b 16 -n -r %d -c %d %s trim 0.0 %f' % (audio_frame_rate, audio_channels, path, float(audio_length) / audio_frame_rate))
try:
os.unlink('video.mp4')
os.unlink('audio.aac')