Skip to content

Instantly share code, notes, and snippets.

View Muqito's full-sized avatar
🦀
Rustacean by heart

Christoffer Lantz Muqito

🦀
Rustacean by heart
View GitHub Profile
@Muqito
Muqito / AV1 Encode.md
Created August 17, 2025 12:07 — forked from mrintrepide/AV1 Encode.md
AV1 quick encode with SVT-AV1

SVT-AV1 is the fastest multithreaded AV1 encoder
You can download up to date BtbN ffmpeg build with latest STV-AV1 code.

Aom-av1 is the official av1 decoder/encoder but it's the slowest and lacks of a real massive multithreading.
Rav1e is a xiph encoder project. It's also very slow but you can use multithreading with tiles.
Dav1d is a veryfast AV1 VLC decoder project.

Svt-av1 is an heavy multithreading intel decoder and encoder. It produce good quality but bigger file size.
It can produce 8 and 10 bit video with CRF (default), CQP, VBR and CBR (test).
Two pass are also available with standalone SvtAv1EncApp but not in ffmpeg.

@Muqito
Muqito / main.rs
Created January 18, 2024 20:23
reduce heap allocation with mem::take
// ref: https://ferrous-systems.com/blog/rustls-borrow-checker-p1/
#[derive(Debug)]
struct Reader<'a> {
buffer: &'a mut [u8]
}
impl<'a> Reader<'a> {
pub fn new(buffer: &'a mut [u8]) -> Self {
Self {
buffer,
}
@Muqito
Muqito / compile-nginx-brotli-modules.sh
Created September 27, 2022 22:46 — forked from jivanpal/compile-nginx-brotli-modules.sh
Compile Brotli modules for Nginx 1.18.0 on Ubuntu 20.04
#!/bin/bash -e
sudo apt install \
curl \
build-essential \
libpcre3-dev \
libssl-dev \
zlib1g-dev \
libxml2-dev \
libxslt1-dev \
@Muqito
Muqito / audit-on-push.yml
Created June 6, 2020 21:45 — forked from LukeMathWalker/audit.yml
GitHub Actions - Rust setup
name: Security audit
on:
push:
paths:
- '**/Cargo.toml'
- '**/Cargo.lock'
jobs:
security_audit:
runs-on: ubuntu-latest
steps:
@Muqito
Muqito / async await ie11.js
Created May 20, 2020 13:00 — forked from DejanBelic/async await ie11.js
How to use async await in ie11
// Async await func
async function getTimelineData() {
var response = await fetch('/some-api-url')
return response.json()
}
async function populateTimelineInit() {
var data = await getTimelineData();
new vis.DataSet(data);
@Muqito
Muqito / what-forces-layout.md
Created March 10, 2020 17:08 — forked from paulirish/what-forces-layout.md
What forces layout/reflow. The comprehensive list.

What forces layout / reflow

All of the below properties or methods, when requested/called in JavaScript, will trigger the browser to synchronously calculate the style and layout*. This is also called reflow or layout thrashing, and is common performance bottleneck.

Element

Box metrics
  • elem.offsetLeft, elem.offsetTop, elem.offsetWidth, elem.offsetHeight, elem.offsetParent
  • elem.clientLeft, elem.clientTop, elem.clientWidth, elem.clientHeight
  • elem.getClientRects(), elem.getBoundingClientRect()