Skip to content

Instantly share code, notes, and snippets.

View Krazete's full-sized avatar
💭
Perpetually behind on every project.

Ted Michael Celis Krazete

💭
Perpetually behind on every project.
View GitHub Profile
@hoshinolina
hoshinolina / arkit.md
Last active November 13, 2026 18:43
ARKit/FaceKit notes

Introduction

ARKit face tracking is shrouded in a ton of myth and mystique.

I reverse engineered the internal face tracking API, and this is how it actually works.

Disclaimer

This is based on reverse engineering the API of Apple's face detection framework and testing it with my own code. Some of it is educated guesswork based on names and strings. I did not reverse engineer the details of how ARKit/FaceKit works, but given what I've seen, I'm quite confident in the overall big picture.

// Downloads video fragments from [Abema global](www.abema-global.com).
// Only downloads 1080p streams.
// Read comments below for how to set `EVENT_ID`, `DEVICE_ID` and `AUTH_HEADER`.
//
// Usage: `node ./abema-downloader.js`
// Tested node version: v22.14.0
import * as fs from "fs";
// The user-visible link to the event is `https://www.abema-global.com/en/lives/<EVENT_ID>`
import re
from PIL import Image
from pathlib import Path
from typing import Iterable, Optional
from argparse import ArgumentParser
import tkinter as tk
from tkinter import filedialog
import UnityPy