hawkeye camera support(not tested)

This commit is contained in:
meelstorm
2025-08-19 12:45:50 +02:00
parent f80b275ad8
commit 6ef6aced8d
170 changed files with 20190 additions and 72 deletions

View File

@@ -0,0 +1,34 @@
using System.Collections.Generic;
namespace Inspectron.HawkEye.RTSP
{
// This class handles the AMR Payload
// It has methods to process the RTP Payload
public class AMRPayload
{
// Constructor
public AMRPayload()
{
}
public List<byte[]> Process_AMR_RTP_Packet(byte[] rtp_payload, int rtp_marker) {
// Octet-Aligned Mode (RFC 4867 Section 4.4.1)
// First byte is the Payload Header
if (rtp_payload.Length < 1) return null;
byte payloadHeader = rtp_payload[0];
// The rest of the RTP packet is the AMR data
List<byte[]> audio_data = new List<byte[]>();
byte[] amr_data = new byte[rtp_payload.Length - 1];
System.Array.Copy(rtp_payload,1,amr_data,0,rtp_payload.Length-1);
audio_data.Add(amr_data);
return audio_data;
}
}
}