DRC

video/x-dirac

Safe

Magic Bytes

Offset: 0
4F 67 67 53 00 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 2E 42 42 43 44

Dirac (DRC) is a wavelet-based video compression format developed by the British Broadcasting Corporation (BBC). It was engineered to facilitate video transmission and storage across a range of resolutions, from internet streaming to ultra-high-definition television. Although largely superseded by contemporary standards such as H.264 and AV1, this legacy format is considered safe and was historically significant for providing a patent-free alternative for media compression.

Extension

.drc

MIME Type

video/x-dirac

Byte Offset

0

Risk Level

Safe

Validation Code

How to validate .drc files in Python

Python
def is_drc(file_path: str) -> bool:
    """Check if file is a valid DRC by magic bytes."""
    signature = bytes([0x4F, 0x67, 0x67, 0x53, 0x00, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x42, 0x42, 0x43, 0x44])
    with open(file_path, "rb") as f:
        return f.read(32) == signature

How to validate .drc files in Node.js

Node.js
function isDRC(buffer: Buffer): boolean {
  const signature = Buffer.from([0x4F, 0x67, 0x67, 0x53, 0x00, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x42, 0x42, 0x43, 0x44]);
  return buffer.subarray(0, 32).equals(signature);
}
Go
func IsDRC(data []byte) bool {
    signature := []byte{0x4F, 0x67, 0x67, 0x53, 0x00, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x2E, 0x42, 0x42, 0x43, 0x44}
    if len(data) < 32 {
        return false
    }
    return bytes.Equal(data[:32], signature)
}

API Endpoint

GET /api/v1/drc
curl https://filesignature.org/api/v1/drc

Related Formats