Documentation
¶
Overview ¶
Package parser extracts release metadata from torrent titles. Designed for scene/p2p naming conventions: e.g. "Show.S01E02.1080p.BluRay.x265-GROUP".
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsPlayable ¶
IsPlayable retorna true se o player provavelmente consegue tocar este release. Magnet vazio → false. Rejeições duras (epub/zip/iso/ebook). Caso contrário usa allowlist de categorias/exts/hints com fallback "true" (preferir oferecer Play e deixar o decoder reclamar do que esconder).
Types ¶
type MediaKind ¶
type MediaKind string
MediaKind é "video" | "audio" | "other". "video" é o default quando o classificador não tem sinal claro — o <video> do PlayerModal toca áudio também, então não-perda; já o AudioBar não renderiza vídeo. Espelhe detectKind() do playable.ts.
func DetectKind ¶
DetectKind decide entre audio / video com base no título + categoria Jackett. Mesma ordem de fallback que o frontend usava (ext > category > hint > default).
type Quality ¶
type Quality struct {
Resolution string `json:"resolution,omitempty"` // 480p, 720p, 1080p, 2160p, 4K
Codec string `json:"codec,omitempty"` // x265, x264, AV1
Source string `json:"source,omitempty"` // BluRay, WEB-DL, WEBRip, HDTV, CAM, TS, DVDRip
Audio []string `json:"audio,omitempty"` // DTS, EAC3, TrueHD, AC3, Atmos, AAC
Group string `json:"group,omitempty"` // YIFY, RARBG, etc.
Year int `json:"year,omitempty"` // detected release year
Season int `json:"season,omitempty"` // S__ when matched
Episode int `json:"episode,omitempty"` // E__ when matched
HDR bool `json:"hdr,omitempty"`
DolbyVis bool `json:"dv,omitempty"`
TenBit bool `json:"tenBit,omitempty"`
Repack bool `json:"repack,omitempty"`
Proper bool `json:"proper,omitempty"`
Extended bool `json:"extended,omitempty"`
Remux bool `json:"remux,omitempty"`
Multi bool `json:"multi,omitempty"` // multi-audio
Dubbed bool `json:"dubbed,omitempty"`
Subbed bool `json:"subbed,omitempty"`
}
Quality holds parsed release metadata. Empty fields mean "not detected".