Moonglade

Modern Markdown blogging with AI-powered localization and search.

Tag: Live Streaming


FFmpeg Usage Overview ★

This article provides a systematic introduction to the core applications and best practices of FFmpeg in video processing. It first compares the pros and cons of encoding formats such as H264, HEVC, VP9, and AV1, recommending HEVC for local storage and suggesting AV1, VP9, or H264 for web distribution based on the target audience. It also provides reference data on the impact of different bitrates, ranging from 1M to 128M, on video quality. The article elaborates on the differences between two working modes: stream copying and stream encoding. The former is efficient but does not allow parameter modification, while the latter is flexible but time-consuming. Additionally, the text includes specific command examples for common operations, such as using FFmpeg to view video metadata, perform transcoding, utilize NVIDIA GPU hardware acceleration, push RTMP live streams (including stream copying and real-time encoding), merge audio and video, burn in subtitles, adjust resolution, change speed, regulate volume, extract segments, crop regions, and reverse videos. Finally, it recommends integrating the SRS open-source project to build low-latency FLV or HLS live streaming services, enabling a localized live streaming experience similar to that of Bilibili.

Views 1,282
FFmpeg Live Streaming SRS Video Editing bash flv.js

Getting the Push Stream URL and Playback URL for Tencent Cloud Live in C#

This article documents the practical process of integrating Tencent Cloud live streaming push functionality in a C# environment. Since Tencent Cloud officially provides code examples only in Java and PHP, and the push URL must be generated on the client side, the author successfully reverse-engineered the Java examples to decipher the generation logic of the critical parameter `txTime`, confirming it to be a Unix timestamp counting from January 1, 1970. Subsequently, the author implemented the complete signing algorithm in C#, including calculating the MD5 value, string concatenation, and conversion to hexadecimal format, ultimately generating valid push and playback addresses. The article details the complete code implementation from timestamp conversion and MD5 encryption to final URL construction, resolving the difficulty C# developers face in understanding the signing mechanism due to the lack of official documentation support. It provides a reusable technical solution and code reference for integrating live streaming features in similar scenarios.

Views 623
.NET Core C# China Live Streaming Tencent Cloud Tencent Cloud Live