feat(transcoding): add FFmpeg HLS transcoding support
- Introduced `TranscodeManager` for managing on-demand transcoding of local video files. - Added configuration options for transcoding in `Config` and `LocalFilesConfig`. - Implemented new API routes for managing transcoding settings, stats, and cache. - Updated `LocalFilesProvider` to support transcoding capabilities. - Created frontend components for managing transcode settings and displaying stats. - Added database migration for transcode settings. - Enhanced existing routes and DTOs to accommodate new transcoding features.
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
"use client";
|
||||
|
||||
import { useState, useEffect } from "react";
|
||||
import { Plus, Upload, RefreshCw, Antenna } from "lucide-react";
|
||||
import { Plus, Upload, RefreshCw, Antenna, Settings2 } from "lucide-react";
|
||||
import { Button } from "@/components/ui/button";
|
||||
import {
|
||||
useChannels,
|
||||
@@ -26,6 +26,7 @@ import {
|
||||
type ChannelImportData,
|
||||
} from "./components/import-channel-dialog";
|
||||
import { IptvExportDialog } from "./components/iptv-export-dialog";
|
||||
import { TranscodeSettingsDialog } from "./components/transcode-settings-dialog";
|
||||
import type {
|
||||
ChannelResponse,
|
||||
ProgrammingBlock,
|
||||
@@ -112,6 +113,7 @@ export default function DashboardPage() {
|
||||
};
|
||||
|
||||
const [iptvOpen, setIptvOpen] = useState(false);
|
||||
const [transcodeOpen, setTranscodeOpen] = useState(false);
|
||||
const [createOpen, setCreateOpen] = useState(false);
|
||||
const [importOpen, setImportOpen] = useState(false);
|
||||
const [importPending, setImportPending] = useState(false);
|
||||
@@ -231,6 +233,16 @@ export default function DashboardPage() {
|
||||
</p>
|
||||
</div>
|
||||
<div className="flex gap-2">
|
||||
{config?.providers?.some((p) => p.capabilities.transcode) && (
|
||||
<Button
|
||||
onClick={() => setTranscodeOpen(true)}
|
||||
title="Transcode settings"
|
||||
className="border-zinc-700 text-zinc-400 hover:text-zinc-100"
|
||||
>
|
||||
<Settings2 className="size-4" />
|
||||
Transcode
|
||||
</Button>
|
||||
)}
|
||||
{capabilities?.rescan && (
|
||||
<Button
|
||||
onClick={() =>
|
||||
@@ -329,6 +341,11 @@ export default function DashboardPage() {
|
||||
)}
|
||||
|
||||
{/* Dialogs / sheets */}
|
||||
<TranscodeSettingsDialog
|
||||
open={transcodeOpen}
|
||||
onOpenChange={setTranscodeOpen}
|
||||
/>
|
||||
|
||||
{token && (
|
||||
<IptvExportDialog
|
||||
open={iptvOpen}
|
||||
|
||||
Reference in New Issue
Block a user