mirror of
https://github.com/koush/scrypted.git
synced 2026-02-03 14:13:28 +00:00
homekit: fix ffmpeg sender when no audio is present
This commit is contained in:
4
plugins/homekit/package-lock.json
generated
4
plugins/homekit/package-lock.json
generated
@@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "@scrypted/homekit",
|
||||
"version": "1.1.68",
|
||||
"version": "1.1.70",
|
||||
"lockfileVersion": 2,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "@scrypted/homekit",
|
||||
"version": "1.1.68",
|
||||
"version": "1.1.70",
|
||||
"dependencies": {
|
||||
"@koush/werift-src": "file:../../external/werift",
|
||||
"check-disk-space": "^3.3.0",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@scrypted/homekit",
|
||||
"version": "1.1.68",
|
||||
"version": "1.1.70",
|
||||
"description": "HomeKit Plugin for Scrypted",
|
||||
"scripts": {
|
||||
"scrypted-setup-project": "scrypted-setup-project",
|
||||
|
||||
@@ -146,7 +146,11 @@ export async function startCameraStreamFfmpeg(device: ScryptedDevice & VideoCame
|
||||
// the packet time parameter is different between LAN and LTE.
|
||||
let opusFramesPerPacket = request.audio.packet_time / 20;
|
||||
|
||||
if (audioCodec === AudioStreamingCodecType.OPUS || audioCodec === AudioStreamingCodecType.AAC_ELD) {
|
||||
const noAudio = mso?.audio === null;
|
||||
if (noAudio) {
|
||||
// no op...
|
||||
}
|
||||
else if (audioCodec === AudioStreamingCodecType.OPUS || audioCodec === AudioStreamingCodecType.AAC_ELD) {
|
||||
// by default opus encodes with a packet time of 20. however, homekit may request another value,
|
||||
// which we will respect by simply outputing frames of that duration, rather than packing
|
||||
// 20 ms frames to accomodate.
|
||||
|
||||
Reference in New Issue
Block a user