Skip to content

Instantly share code, notes, and snippets.

View TiZ-HugLife's full-sized avatar

Trent McPheron TiZ-HugLife

View GitHub Profile
@agranig
agranig / hitbox-stream
Created July 28, 2014 11:11
stream to hitbox.tv from your linux command line
# the key you get from http://www.hitbox.tv/settings/youruser/livestreams
HITBOX_KEY="youruser?key=xxxxx"
# top-left corner of capture window
CAPTURE_POS="250,200"
# width/height of capture window
CAPTURE_SIZE="1050x600"
# make sure to have a really recent ffmpeg version (0.10.12 works fine)
ffmpeg -f x11grab -show_region 1 \
-s ${CAPTURE_SIZE} -r 25 -i :0.0+${CAPTURE_POS} \
@whoacowboy
whoacowboy / get-props-and-methods-daz3d.dsa
Last active November 6, 2022 23:51
Daz3D script for getting the properties and methods of the global objects.
// DAZ Studio version 4.7.0.12 filetype DAZ Script
function propsAndMethods(obj) {
var classInfo = obj.name + " (" + obj.className() + ")";
var seperator = "";
for (var i = 0; i < classInfo.length; i++){
seperator += '_';
}
print(seperator);
print(classInfo);
@Brainiarc7
Brainiarc7 / VAAPI-hwaccel-encode-Linux-Ffmpeg&Libav-setup.md
Last active March 26, 2024 18:18
This gist contains instructions on setting up FFmpeg and Libav to use VAAPI-based hardware accelerated encoding (on supported platforms) for H.264 (and H.265 on supported hardware) video formats.

Using VAAPI's hardware accelerated video encoding on Linux with Intel's hardware on FFmpeg and libav

Hello, brethren :-)

As it turns out, the current version of FFmpeg (version 3.1 released earlier today) and libav (master branch) supports full H.264 and HEVC encode in VAAPI on supported hardware that works reliably well to be termed "production-ready".

@Brainiarc7
Brainiarc7 / ffmppeg-advanced-playbook-nvenc-and-libav-and-vaapi.md
Last active May 5, 2023 01:51
FFMpeg's playbook: Advanced encoding options with hardware-accelerated acceleration for both NVIDIA NVENC's and Intel's VAAPI-based hardware encoders in both ffmpeg and libav.

FFmpeg and libav's playbook: Advanced encoding options with hardware-based acceleration, NVIDIA's NVENC and Intel's VAAPI-based encoder.

Hello guys,

Continuing from this guide to building ffmpeg and libav with NVENC and VAAPI enabled, this snippet will cover advanced options that you can use with ffmpeg and libav on both NVENC and VAAPI hardware-based encoders.

For ffmpeg:

@Brainiarc7
Brainiarc7 / ffmpeg-desktop-livestreaming-nvenc-and netcat.md
Last active May 12, 2024 20:32
This gist will show you how to livestream your Linux desktop to a client via FFMpeg using a GPU-accelerated video encoder (NVENC and VAAPI-based)

Low-Latency Live Streaming for your Desktop using ffmpeg and netcat:

Preamble:

In this post I will explore how to stream a video and audio capture from one computer to another using ffmpeg and netcat, with a latency below 100ms, which is good enough for presentations and general purpose remote display tasks on a local network.

The problem:

Streaming low-latency live content is quite hard, because most software-based video codecs are designed to achieve the best compression and not best latency. This makes sense, because most movies are encoded once and decoded often, so it is a good trade-off to use more time for the encoding than the decoding.

@Brainiarc7
Brainiarc7 / skylake-tuning-linux.md
Last active July 14, 2024 12:33
This gist will show you how to tune your Intel-based Skylake, Kabylake and beyond Integrated Graphics Core for performance and reliability through GuC and HuC firmware usage on Linux.

Tuning Intel Skylake and beyond for optimal performance and feature level support on Linux:

Note that on Skylake, Kabylake (and the now cancelled "Broxton") SKUs, functionality such as power saving, GPU scheduling and HDMI audio have been moved onto binary-only firmware, and as such, the GuC and the HuC blobs must be loaded at run-time to access this functionality.

Enabling GuC and HuC on Skylake and above requires a few extra parameters be passed to the kernel before boot.

Instructions provided for both Fedora and Ubuntu (including Debian):

Note that the firmware for these GPUs is often packaged by your distributor, and as such, you can confirm the firmware blob's availability by running: