docs: regenerate HTML/WASM docs with video vs clip comparison + timestamps

This commit is contained in:
Accusys
2026-05-19 12:51:10 +08:00
parent 5b2f9b35bf
commit c9bcdcb56a
28 changed files with 188 additions and 0 deletions
+91
View File
@@ -273,6 +273,95 @@ curl<span class="w"> </span>-s<span class="w"> </span><span class="s2">&quot;</s
</tr>
</tbody>
</table>
<h3>Video vs Clip: Quality &amp; Format Comparison</h3>
<p>Both endpoints support time range extraction, but serve different use cases:</p>
<table class="table">
<thead>
<tr>
<th>Feature</th>
<th><code>/video</code></th>
<th><code>/clip</code></th>
</tr>
</thead>
<tbody>
<tr>
<td><strong>No params</strong></td>
<td>Streams full file (Range seek)</td>
<td>Returns 400 (params required)</td>
</tr>
<tr>
<td><strong>HTTP Range</strong></td>
<td>✅ Supported</td>
<td>❌ Not supported</td>
</tr>
<tr>
<td><strong>Encoding</strong></td>
<td><code>-c copy</code> (zero encoding)</td>
<td><code>-c:v libx264 -c:a aac</code> (re-encode)</td>
</tr>
<tr>
<td><strong>Quality</strong></td>
<td>Original (bit-exact, zero loss)</td>
<td>Compressed (default CRF ≈ 23)</td>
</tr>
<tr>
<td><strong>Format</strong></td>
<td><code>video/mp4</code></td>
<td><code>video/mp2t</code> (MPEG-TS)</td>
</tr>
<tr>
<td><strong>Speed</strong></td>
<td>Fast (no computation)</td>
<td>Slower (encoding required)</td>
</tr>
<tr>
<td><strong>Frame control</strong></td>
<td>Time-based (<code>dur = (ef-sf)/fps</code>)</td>
<td>Precise (<code>-vframes</code>)</td>
</tr>
<tr>
<td><strong>Debug mode</strong></td>
<td></td>
<td><code>mode=debug</code> overlay</td>
</tr>
<tr>
<td><strong>Cache</strong></td>
<td></td>
<td><code>max-age=86400</code></td>
</tr>
</tbody>
</table>
<h4>Usage Recommendation</h4>
<table class="table">
<thead>
<tr>
<th>Scenario</th>
<th>Use</th>
</tr>
</thead>
<tbody>
<tr>
<td>Full video streaming / player seek</td>
<td><code>/video</code></td>
</tr>
<tr>
<td>Quick preview clip (zero quality loss)</td>
<td><code>/video?start_frame=...&amp;end_frame=...</code></td>
</tr>
<tr>
<td>Debug frame verification / text overlay</td>
<td><code>/clip?mode=debug</code></td>
</tr>
<tr>
<td>Precise frame count control</td>
<td><code>/clip</code></td>
</tr>
<tr>
<td>CDN cacheable clip</td>
<td><code>/clip</code></td>
</tr>
</tbody>
</table>
<hr />
<table class="table">
<thead>
@@ -304,6 +393,8 @@ curl<span class="w"> </span>-s<span class="w"> </span><span class="s2">&quot;</s
</tr>
</tbody>
</table>
<hr />
<p><em>Updated: 2026-05-19 12:49:24</em></p>
</div>
</body>
</html>