
Recherche avancée
Autres articles (18)
-
Organiser par catégorie
17 mai 2013, parDans MédiaSPIP, une rubrique a 2 noms : catégorie et rubrique.
Les différents documents stockés dans MédiaSPIP peuvent être rangés dans différentes catégories. On peut créer une catégorie en cliquant sur "publier une catégorie" dans le menu publier en haut à droite ( après authentification ). Une catégorie peut être rangée dans une autre catégorie aussi ce qui fait qu’on peut construire une arborescence de catégories.
Lors de la publication prochaine d’un document, la nouvelle catégorie créée sera proposée (...) -
Les thèmes de MediaSpip
4 juin 20133 thèmes sont proposés à l’origine par MédiaSPIP. L’utilisateur MédiaSPIP peut rajouter des thèmes selon ses besoins.
Thèmes MediaSPIP
3 thèmes ont été développés au départ pour MediaSPIP : * SPIPeo : thème par défaut de MédiaSPIP. Il met en avant la présentation du site et les documents média les plus récents ( le type de tri peut être modifié - titre, popularité, date) . * Arscenic : il s’agit du thème utilisé sur le site officiel du projet, constitué notamment d’un bandeau rouge en début de page. La structure (...) -
Gestion des droits de création et d’édition des objets
8 février 2011, parPar défaut, beaucoup de fonctionnalités sont limitées aux administrateurs mais restent configurables indépendamment pour modifier leur statut minimal d’utilisation notamment : la rédaction de contenus sur le site modifiables dans la gestion des templates de formulaires ; l’ajout de notes aux articles ; l’ajout de légendes et d’annotations sur les images ;
Sur d’autres sites (5752)
-
Playing RTP stream on Android 4.1.2 (Jelly Bean) [closed]
27 décembre 2024, par Homie_TomieI'll try to keep it quick. Using FFMPEG I started a stream on my PC. Here is the code :


import subprocess

def start_stream():
 command = [
 'ffmpeg',
 '-f', 'gdigrab', # Desktop capture (Windows)
 '-framerate', '15', # Low framerate for higher performance
 '-i', 'desktop', # Capture desktop
 '-c:v', 'libx264', # Video codec (H.264)
 '-preset', 'ultrafast', # Ultra-fast encoding preset for minimal latency
 '-tune', 'zerolatency', # Zero latency for real-time streaming
 '-x264opts', 'keyint=15:min-keyint=15:no-scenecut', # Frequent keyframes
 '-b:v', '500k', # Low bitrate to minimize data usage and reduce latency
 '-s', '800x480', # Resolution fits phone screen and helps performance
 '-max_delay', '0', # No buffering, instant frame output
 '-flush_packets', '1', # Flush packets immediately after encoding
 '-f', 'rtp', # Use mpegts as the container for RTP stream
 'rtp://192.168.72.26:1234', # Stream over UDP to localhost on port 1234
 '-sdp_file', 'stream.sdp' # Create SDP file
 ]
 
 try:
 print("Starting stream...")
 subprocess.run(command, check=True)
 except subprocess.CalledProcessError as e:
 print(f"Error occurred: {e}")
 except KeyboardInterrupt:
 print("\nStream interrupted")

if __name__ == "__main__":
 print("Starting screen capture...")
 start_stream()



Now, when I start the stream I can connect to it in VLC when I open up the stream.sdp file. Using the same method I can open up the stream on my iPhone, but when I try to open it on my old Android phone the stream connects but the screen is black. However, when I turn the screen I can see the first frame that was sent to the phone. Why does the stream not work ?


I will be thankful for any and all advice :)


-
iOS Radio App : Need to extract and stream audio-only from HLS streams with video content
20 décembre 2024, par Bader AlghamdiI'm developing an iOS radio app that plays various HLS streams. The challenge is that some stations broadcast HLS streams containing both audio and video (example : https://svs.itworkscdn.net/smcwatarlive/smcwatar/chunks.m3u8), but I want to :


Extract and play only the audio track
Support AirPlay for audio-only streaming
Minimize data usage by not downloading video content
Technical Details :


iOS 17+
Swift 6
Using AVFoundation for playback
Current implementation uses AVPlayer with AVPlayerItem
Current Code Structure :


class StreamPlayer: ObservableObject { @Published var isPlaying = false private var player: AVPlayer? private var playerItem: AVPlayerItem?

func playStream(url: URL) {
 let asset = AVURLAsset(url: url)
 playerItem = AVPlayerItem(asset: asset)
 player = AVPlayer(playerItem: playerItem)
 player?.play()
}




Stream Analysis : When analyzing the video stream using FFmpeg :


CopyInput #0, hls, from 'https://svs.itworkscdn.net/smcwatarlive/smcwatar/chunks.m3u8':
 Stream #0:0: Video: h264, yuv420p(tv, bt709), 1920x1080 [SAR 1:1 DAR 16:9], 25 fps
 Stream #0:1: Audio: aac, 44100 Hz, stereo, fltp




Attempted Solutions :


Using MobileFFmpeg :


let command = [
 "-i", streamUrl,
 "-vn",
 "-acodec", "aac",
 "-ac", "2",
 "-ar", "44100",
 "-b:a", "128k",
 "-f", "mpegts",
 "udp://127.0.0.1:12345"
].joined(separator: " ")

ffmpegProcess = MobileFFmpeg.execute(command)

I



ssue : While FFmpeg successfully extracts audio, playback through AVPlayer doesn't work reliably.


Tried using HLS output :


let command = [
 "-i", streamUrl,
 "-vn",
 "-acodec", "aac",
 "-ac", "2",
 "-ar", "44100",
 "-b:a", "128k",
 "-f", "hls",
 "-hls_time", "2",
 "-hls_list_size", "3",
 outputUrl.path
]




Issue : Creates temporary files but faces synchronization issues with live streams.



Testing URLs :


Audio+Video : https://svs.itworkscdn.net/smcwatarlive/smcwatar/chunks.m3u8
Audio Only : https://mbcfm-radio.mbc.net/mbcfm-radio.m3u8



Requirements :


- 

- Real-time audio extraction from HLS stream
- Maintain live streaming capabilities
- Full AirPlay support
- Minimal data usage (avoid downloading video content)
- Handle network interruptions gracefully












Questions :


- 

- What's the most efficient way to extract only audio from an HLS stream in real-time ?
- Is there a way to tell AVPlayer to ignore video tracks completely ?
- Are there better alternatives to FFmpeg for this specific use case ?
- What's the recommended approach for handling AirPlay with modified streams ?










Any guidance or alternative approaches would be greatly appreciated. Thank you !


What I Tried :


- 

- Direct AVPlayer Implementation :




- 

- Used standard AVPlayer to play HLS stream
- Expected it to allow selecting audio-only tracks
- Result : Always downloads both video and audio, consuming unnecessary bandwidth









- 

- FFmpeg Audio Extraction :




let command = [
 "-i", "https://svs.itworkscdn.net/smcwatarlive/smcwatar/chunks.m3u8",
 "-vn", // Remove video
 "-acodec", "aac", // Audio codec
 "-ac", "2", // 2 channels
 "-ar", "44100", // Sample rate
 "-b:a", "128k", // Bitrate
 "-f", "mpegts", // Output format
 "udp://127.0.0.1:12345" // Local stream
]
ffmpegProcess = MobileFFmpeg.execute(command)




Expected : Clean audio stream that AVPlayer could play
Result : FFmpeg extracts audio but AVPlayer can't play the UDP stream



- 

- HLS Segmented Approach :




swiftCopylet command = [
 "-i", streamUrl,
 "-vn",
 "-acodec", "aac",
 "-f", "hls",
 "-hls_time", "2",
 "-hls_list_size", "3",
 outputUrl.path
]




Expected : Create local HLS playlist with audio-only segments
Result : Creates files but faces sync issues with live stream



Expected Behavior :


- 

- Stream plays audio only
- Minimal data usage (no video download)
- Working AirPlay support
- Real-time playback without delays










Actual Results :


- 

- Either downloads full video stream (wasteful)
- Or fails to play extracted audio
- AirPlay issues with modified streams
- Sync problems with live content










-
What is the ideal image format extraction for YUV color space and lossless compression from mxf video format using ffmpeg
15 février 2016, par DragonDance27I would like to be able to work on frames from an .mxf video file. The image format of the video is JPEG 2000, using a YUV color space with 4:2:2 subsampling and lossless compression.
My intentions are to extract frames from this video using ffmpeg. Extracted frames would then be processed in Matlab (at the moment I’m interested in performing colorization).
I want to extract the frames with as minimal data loss as possible and I would like to work in the YUV color space. I understand PNG involves a lossless process, but only involves the RGB color space - so not an option.
I think I can extract jpeg2000 frames in the YUV color space, but I’m not sure if I’m losing data from the compression process. I attempted the following code in ffmpeg :
ffmpeg -i video.mxf -r 1/5 out%03d.jp2
... however, the extracted jp2 files are unreadable in various software, including HiView which is a specialised JPEG 2000 software.
Quesiton 1 : Is this jpeg 2000 extraction method lossless ? What am I doing wrong ?
I also considered extracting the images in the tiff format where I can achieve the YUV and lossless requirements. I attempted the following code in ffmpeg :
ffmpeg -i video.mxf -vcodec tiff f%10d.tif
... however, the extracted tiff files are unreadable in software such as paint, paint.net and windows photo viewer.
Question 2 : Is this tiff extraction method correct ? What am I doing wrong ?
Question 3 : What is an ideal image format that covers my YUV and lossless requirements ?