mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-17 03:53:29 +01:00
Allow seeking for FFmpeg
This commit is contained in:
@@ -66,6 +66,7 @@ export default class AudioEncoder {
|
|||||||
'-f', 's16le',
|
'-f', 's16le',
|
||||||
'-ar', '48000',
|
'-ar', '48000',
|
||||||
'-af', 'volume=' + (options.volume || 1),
|
'-af', 'volume=' + (options.volume || 1),
|
||||||
|
'-ss', (options.seek || 0),
|
||||||
'-ac', 2,
|
'-ac', 2,
|
||||||
'pipe:1'
|
'pipe:1'
|
||||||
], {stdio: ['pipe', 'pipe', 'ignore']});
|
], {stdio: ['pipe', 'pipe', 'ignore']});
|
||||||
@@ -100,6 +101,7 @@ export default class AudioEncoder {
|
|||||||
'-f', 's16le',
|
'-f', 's16le',
|
||||||
'-ar', '48000',
|
'-ar', '48000',
|
||||||
'-af', 'volume=' + (options.volume || 1),
|
'-af', 'volume=' + (options.volume || 1),
|
||||||
|
'-ss', (options.seek || 0),
|
||||||
'-ac', 2,
|
'-ac', 2,
|
||||||
'pipe:1'
|
'pipe:1'
|
||||||
], { stdio: ['pipe', 'pipe', 'ignore'] });
|
], { stdio: ['pipe', 'pipe', 'ignore'] });
|
||||||
|
|||||||
Reference in New Issue
Block a user