add timecode field to encoding

This commit is contained in:
2024-12-26 12:30:57 -06:00
parent 245e092e3d
commit cf5c5f5429
2 changed files with 39 additions and 0 deletions
+30
View File
@@ -29,6 +29,36 @@ const goodTests = [
data: new Uint8Array([]),
},
},
{
description: 'DDP packet with timecode',
expected: new Uint8Array([0x50, 0x0f, 0x92, 0x01, 0x45, 0x67, 0x89, 0x10, 0x10, 0x11, 0x10, 0x11, 0x11, 0x10]),
packet: {
header: {
flags: {
version: 1,
timecode: true,
storage: false,
reply: false,
query: false,
push: false,
},
sequenceNumber: 15,
dataType: {
standard: false,
type: 2,
bitsPerPixel: 4,
},
sourceOrDestinationID: 1,
dataOffset: 1164413200,
dataLength: 4113,
timecode: {
seconds: 4113,
fractionalSeconds: 4368,
},
},
data: new Uint8Array([]),
},
},
];
const badTests = [];