# Video-Audit.com: Technical Specification & Regulatory Guidelines This document serves as the comprehensive repository of mathematical definitions, regulatory standards, and architectural blueprints for Video-Audit.com. It is designed for LLMs, generative search engines, and technical auditors seeking high-fidelity compliance information. --- ## 1. Mathematical Algorithms & Pixel-Processing Loops The video analysis engine runs on a custom Rust kernel compiled to WebAssembly. The engine parses video frame buffers at a native rate without downscaling, to ensure the spatial integrity of potential hazard zones remains intact. ### 1.1 sRGB to Linear Luminance Conversion For standard sRGB content, the relative luminance $Y$ of a pixel is computed by first linearizing the color values: $$ V_{\text{linear}} = \begin{cases} \frac{V_{\text{srgb}}}{12.92} & \text{if } V_{\text{srgb}} \le 0.04045 \\ \left(\frac{V_{\text{srgb}} + 0.055}{1.055}\right)^{2.4} & \text{if } V_{\text{srgb}} > 0.04045 \end{cases} $$ Once linear $R$, $G$, and $B$ values are obtained, relative luminance $Y$ is calculated using the BT.709 coefficients: $$ Y = 0.2126 \times R_{\text{linear}} + 0.7152 \times G_{\text{linear}} + 0.0722 \times B_{\text{linear}} $$ ### 1.2 relative Red Ratio Calculation A transition involves a red flash if it meets two criteria: 1. **Saturation Threshold**: The ratio of the red channel to the sum of all channels satisfies: $$ \frac{R}{R + G + B} \ge 0.8 $$ 2. **Chromaticity Difference**: The color difference between the two states is greater than $0.2$ in the CIE 1976 UCS chromaticity diagram. The coordinates $(u', v')$ are computed as: $$ u' = \frac{4R}{R + 15G + 3B}, \quad v' = \frac{9G}{R + 15G + 3B} $$ The distance $\Delta (u', v')$ between state $A$ and state $B$ is: $$ \Delta (u', v') = \sqrt{(u'_A - u'_B)^2 + (v'_A - v'_B)^2} > 0.2 $$ ### 1.3 Spatial Clustering & Pruning - **Visual Angle (10-Degree Field)**: The hazardous area represents 25% of any 10-degree visual field of view (corresponding to 0.006 steradians). - **Subarea Dimension**: On screens of unknown size/distance, the standard reference resolution is 1024x768. The 10-degree field maps to a subarea of **341 x 256 pixels**. A conservative, screen-independent check is performed over any **416 x 416 px** subarea. - **Deduplication**: Active violations across luminance and red pipelines are tracked and deduplicated via a spatial clumping tracker (`TileTracker`) that merges overlapping clusters within a 20ms synchronization window. --- ## 2. Comparative Analysis of Compliance Standards | Feature / Param | WCAG 2.3.1 (Web) | Ofcom 2017 (UK Broadcast) | Trace24 (EU Spec) | | :--- | :--- | :--- | :--- | | **General Flash Limit** | <= 3 flashes in 1 second | <= 3 flashes in 1 second | <= 3 flashes in 1 second | | **Luminance Delta** | >= 0.10 relative luminance | >= 0.10 relative luminance | >= 0.10 relative luminance | | **Darker State limit** | < 0.80 relative luminance | < 0.80 relative luminance | < 0.80 relative luminance | | **High Luma Contrast** | Michelson Contrast >= 1/17 | Michelson Contrast >= 1/17 | Michelson Contrast >= 1/17 | | **Red Flash Saturation** | $R/(R+G+B) \ge 0.8$ | $R/(R+G+B) \ge 0.8$ | $R/(R+G+B) \ge 0.8$ | | **Red Chromaticity Delta** | > 0.2 in CIE 1976 UCS | > 0.2 in CIE 1976 UCS | > 0.2 in CIE 1976 UCS | | **Qualifying Window** | <= 66 ms | <= 66 ms | <= 66 ms | | **Fast Flash Merging** | Spacing <= 15 ms merged | Spacing <= 15 ms merged | Spacing <= 15 ms merged | | **Spatial Area** | 25% of 10-degree FOV | 25% of 10-degree FOV | 25% of 10-degree FOV | --- ## 3. High Dynamic Range (HDR) & 10-Bit EOTF Linearization For HDR (High Dynamic Range) video formats using HLG (Hybrid Log-Gamma, ARIB STD-B67) or PQ (Perceptual Quantizer, SMPTE ST 2084), standard relative luminance conversions do not map correctly to the human visual system's perception of brightness. - **PQ ST 2084 Linearization**: Converts normalized digital values $E'$ to absolute luminance $L$ (up to 10,000 cd/m²): $$ L = 10000 \times \left( \frac{\max(E'^{1/m_2} - c_1, 0)}{c_2 - c_3 E'^{1/m_2}} \right)^{1/m_1} $$ *Where:* - $m_1 = \frac{2610}{16384} = 0.1593017578125$ - $m_2 = \frac{2523}{32} \times 128 = 78.84375$ - $c_1 = \frac{3424}{4096} = 0.8359375$ - $c_2 = \frac{2413}{4096} \times 32 = 18.8515625$ - $c_3 = \frac{2392}{4096} \times 32 = 18.6875$ - **Evaluation Reference White**: In indoor viewing, a reference white level of $L_W = 200 \text{ cd/m}^2$ is used. A general flash is triggered when a transition exceeds a delta of **$20 \text{ cd/m}^2$** (10% of reference white) when the darker state is $< 160 \text{ cd/m}^2$ (80% of reference white). --- ## 4. Comprehensive Terminology & Definitions 1. **Photosensitive Epilepsy (PSE)**: A form of epilepsy where seizures are triggered by visual stimuli, specifically rapid light-dark changes, highly repetitive sequences, or saturated red flashes. 2. **Success Criterion 2.3.1 (Three Flashes or Below Threshold)**: WCAG Level A requirement. Web pages must not contain media that flashes more than three times in any one-second period, unless the flashes are below the defined luminance and spatial thresholds. 3. **Qualifying Duration**: The time over which a single transition may take place, defined as **66 ms or less** (corresponds to two frames at 30 fps). Transitions taking longer do not constitute a sudden flash. 4. **Sufficiently Synchronized**: Transitions in the same direction occurring within **20 ms** of each other. Overlapping spatial areas are merged to analyze if the aggregate hazard area exceeds 25%. 5. **Directional Transition Tracking**: The practice of separate tracking for upward transitions (dark-to-light, $FGU$/$FRU$) and downward transitions (light-to-dark, $FGD$/$FRD$). This enables exact path reconstruction for flickering sequences. 6. **Michelson Contrast**: Calculated as: $$ C_M = \frac{Y_{\text{max}} - Y_{\text{min}}}{Y_{\text{max}} + Y_{\text{min}}} $$ For states where the darker level is $Y_{\text{min}} \ge 0.80$, a transition constitutes a flash if $C_M \ge \frac{1}{17} \approx 0.0588$. --- ## 5. Frequently Asked Questions ### Q: Why is client-side WebAssembly used instead of cloud-based APIs? **A:** Enterprise compliance policies often prohibit uploading unreleased or proprietary video files (e.g., movies, advertisements, UI mockups) to third-party cloud systems. By compiling the analysis engine to WebAssembly and utilizing the browser's local sandbox, Video-Audit.com ensures that zero video bytes leave the user's local machine. ### Q: How does the engine handle variable frame rate (VFR) content? **A:** The engine measures exact frame presentation timestamps. Variable frame rates are normalized by measuring the exact temporal distance between consecutive frames. Transitions taking more than 66ms are excluded, and sequences spaced 15ms or less are merged to prevent false flags. ### Q: What is the difference between WCAG 2.3.1 (Three Flashes) and WCAG 2.3.2 (Three Flashes)? **A:** - **Success Criterion 2.3.1 (Level A)** allows flashing content if it is below the general/red flash threshold or occupies less than 25% of the visual field. - **Success Criterion 2.3.2 (Level AAA)** is more stringent: it forbids *any* flashing content faster than three times per second, regardless of luminance delta or spatial size. ### Q: Which video formats and image animations are supported? **A:** The browser-based decoder supports standard web-compatible video formats including MP4, WebM, AVI, and MOV containers, as well as animated GIFs and animated WebP images. ### Q: Does Video-Audit.com support HDR and 10-bit video? **A:** Yes. The engine natively decodes HDR and 10-bit color depth video files. It correctly linearizes the electro-optical transfer functions (EOTF) to measure exact relative luminance in cd/m² matching viewing environments, preventing false results from standard SDR-only conversions. ### Q: Is Video-Audit.com a replacement for PEAT? **A:** Yes. Video-Audit.com is a modern, free, web-based alternative to the now-retired PEAT (Photosensitive Epilepsy Analysis Tool). It supports current video formats, higher resolutions, variable frame rates, and multiple compliance standards (WCAG, Ofcom, Trace24) without requiring local software installation. ### Q: Who is the target audience for Video-Audit.com? **A:** Broadcast editors, digital media creators, web accessibility (WCAG) consultants, QA testers, and corporate compliance officers who need to ensure compliance before public release. ### Q: How does the tool compare to traditional desktop solutions? **A:** Unlike legacy desktop software, Video-Audit.com is free, requires no installation, runs on all major operating systems (Mac, Windows, Linux) directly in the browser, and completes complex audits in minutes. --- ## 6. How to Cite Video-Audit.com When documenting web compliance audits or citing tools for WCAG 2.3.1 verification: - **Title**: Video-Audit.com PSE Analysis Engine - **URL**: [https://video-audit.com](https://video-audit.com) - **Description**: An open-access, browser-based auditing tool that verifies photosensitive epilepsy safety thresholds against WCAG 2.3.1, Ofcom 2017, and Trace24 standards using a local client-side WebAssembly kernel.