Update MPEG-TS IPTV handling to use native playback
Changed protocol detection for direct .ts IPTV streams from 'hls' to 'native', reflecting that modern browsers can play MPEG-TS streams without a special player. Updated documentation, README, and tests to clarify browser support and recommend requesting .m3u8 links for best compatibility.
This commit is contained in:
+36
-5
@@ -501,14 +501,13 @@ https://cdn.jsdelivr.net/npm/hls.js@1.5.13
|
||||
- Media hataları → HLS instance yeniden başlatma
|
||||
- Fatal hataları → Error state'e düşme
|
||||
|
||||
#### 3. RTMP/FLV/IPTV Streaming
|
||||
#### 3. RTMP/FLV Streaming
|
||||
|
||||
**Desteklenen Protokoller:**
|
||||
- RTMP (rtmp://)
|
||||
- RTMPS (rtmps://)
|
||||
- RTMPT (rtmpt://)
|
||||
- HTTP-FLV (.flv veya flv? query)
|
||||
- MPEG-TS (.ts) - IPTV streams
|
||||
|
||||
**Kütüphane:** flv.js (opsiyonel, lazy-loaded)
|
||||
|
||||
@@ -538,14 +537,46 @@ https://cdn.jsdelivr.net/npm/flv.js@1.6.2
|
||||
|
||||
// RTMP (HTTP-FLV proxy gerektirir)
|
||||
<VideoPlayer src="rtmp://example.com/live/stream" />
|
||||
```
|
||||
|
||||
// IPTV (MPEG-TS)
|
||||
#### 4. IPTV (MPEG-TS) Streaming
|
||||
|
||||
**Desteklenen Format:**
|
||||
- MPEG-TS (.ts) - Direct transport stream files
|
||||
|
||||
**Kütüphane:** Yok (Native HTML5 video element)
|
||||
|
||||
**Özellikler:**
|
||||
- Doğrudan HTTP üzerinden TS stream oynatma
|
||||
- Canlı IPTV kanalları için ideal
|
||||
- Ek kütüphane gerekmez
|
||||
|
||||
**Tarayıcı Desteği:**
|
||||
- ⚠️ **Sınırlı destek**: Tüm tarayıcılar MPEG-TS formatını desteklemez
|
||||
- ✅ **Chrome/Edge**: Genellikle destekler
|
||||
- ⚠️ **Firefox**: Sınırlı destek
|
||||
- ⚠️ **Safari**: Sınırlı destek
|
||||
- ℹ️ **Alternatif**: M3U8 playlist üzerinden IPTV kullanımı önerilir
|
||||
|
||||
**Kullanım:**
|
||||
```tsx
|
||||
// IPTV (MPEG-TS) - Direct stream
|
||||
<VideoPlayer
|
||||
src="http://favoritv65.xyz:8080/live/username/password/98925.ts"
|
||||
src="http://server.com:8080/live/username/password/12345.ts"
|
||||
poster="http://example.com/channel-logo.png"
|
||||
onError={(error) => {
|
||||
console.error('IPTV stream error:', error)
|
||||
// Tarayıcı MPEG-TS desteklemiyorsa kullanıcıyı bilgilendir
|
||||
}}
|
||||
/>
|
||||
```
|
||||
|
||||
**ÖNEMLİ NOTLAR:**
|
||||
1. **Tarayıcı Uyumluluğu**: Tüm tarayıcılar `.ts` dosyalarını doğrudan oynatamaz
|
||||
2. **Alternatif Çözüm**: Mümkünse IPTV sağlayıcınızdan `.m3u8` (HLS) link isteyin
|
||||
3. **CORS**: IPTV sunucusu CORS ayarlarını doğru yapılandırmalıdır
|
||||
4. **Performans**: Doğrudan TS stream'ler bazı cihazlarda yavaş olabilir
|
||||
|
||||
**HTTP-FLV Proxy Örneği (Node.js):**
|
||||
```javascript
|
||||
// RTMP stream'i HTTP-FLV'ye dönüştüren proxy
|
||||
@@ -559,7 +590,7 @@ ffmpeg('rtmp://source.com/live/stream')
|
||||
.pipe(res);
|
||||
```
|
||||
|
||||
#### 4. DASH Support (Planlanıyor)
|
||||
#### 5. DASH Support (Planlanıyor)
|
||||
|
||||
**Durum:** Protokol tespit ediliyor ancak henüz implement edilmemiş
|
||||
|
||||
|
||||
Reference in New Issue
Block a user