This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Make sure you opened the x64 Native Tools Command Prompt for VS 2022 and then opened MSYS2 shell command | |
echo Compiling ffmpeg... | |
git clone https://git.ffmpeg.org/ffmpeg.git ffmpeg | |
cd ../build | |
mkdir ffmpeg | |
cd ffmpeg | |
CC=cl \ | |
PKG_CONFIG_PATH="$PKG_CONFIG_PATH:../../installed/x264/lib/pkgconfig:../../installed/x265/lib/pkgconfig:../../installed/SDL/lib/pkgconfig" \ | |
../../sources/ffmpeg/configure \ | |
--prefix=../../installed/ffmpeg \ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Make sure you opened the x64 Native Tools Command Prompt for VS 2022 and then opened MSYS2 shell command | |
echo Getting SDL... | |
git clone https://github.com/libsdl-org/SDL.git -b SDL2 | |
cd ../build | |
mkdir SDL | |
cd SDL | |
cmake -G "Visual Studio 17 2022" -A x64 -DCMAKE_INSTALL_PREFIX="../../installed/SDL" -DSDL_STATIC=ON -DSDL_SHARED=OFF ../../sources/SDL | |
cmake --build . --config Debug --target install |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Make sure you opened the x64 Native Tools Command Prompt for VS 2022 and then opened MSYS2 shell command | |
echo Getting libvpx... | |
git clone --depth 1 https://chromium.googlesource.com/webm/libvpx.git | |
cd ../build | |
mkdir libvpx | |
cd libvpx | |
../../sources/libvpx/configure --target=x86_64-win64-vs17 --enable-static --enable-static-msvcrt --disable-examples --disable-tools --disable-docs --disable-unit-tests --prefix="../../installed/libvpx" | |
make | |
make install | |
mv ../../installed/libvpx/lib/x64/vpxmt.lib ../../installed/libvpx/lib/x64/vpx.lib |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Make sure you opened the x64 Native Tools Command Prompt for VS 2022 and then opened MSYS2 shell command | |
git clone https://bitbucket.org/multicoreware/x265_git | |
mv x265_git x265 | |
# Modify "ffmpeg_build/sources/x265/source/CMakeLists.txt with the following edit | |
# | |
# add_definitions(/Ob2) # always inline | |
# | |
# To: | |
# if(CMAKE_BUILD_TYPE STREQUAL "Release") | |
# add_definitions(/Ob2) # always inline, only for release |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Make sure you opened the x64 Native Tools Command Prompt for VS 2022 and then opened MSYS2 shell command | |
git clone https://code.videolan.org/videolan/x264.git | |
cd x264 | |
cd ../../build | |
mkdir x264 | |
cd x264 | |
CC=cl ../../sources/x264/configure --prefix=../../installed/x264 --enable-static --disable-cli --enable-debug --extra-cflags="-MTd -Od -Zi -RTC1 -W4" --extra-ldflags="-DEBUG" | |
make | |
make install |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import wave | |
import struct | |
import math | |
# Audio parameters | |
sample_width = 2 | |
sample_rate = 44100 | |
duration = 5 | |
# Define the melody |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import random | |
from PIL import Image | |
def create_random_image(width, height): | |
# Create a new blank image with RGB mode | |
image = Image.new('RGB', (width, height)) | |
# Create a pixel map | |
pixels = image.load() |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from tkinter import Tk | |
from tkinter.filedialog import askopenfilename | |
from pathlib import Path | |
import subprocess | |
Tk().withdraw() | |
input_file = Path(askopenfilename(title='Load video file', initialdir=f"{Path.home()}")) | |
input_projection = 'equirect' | |
output_projection = ['c3x2', 'c6x1', 'c1x6', | |
'eac', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ffmpeg -re -i INPUT -c:v libx264 -c:a aac -preset slower -f dash ARBITRARY_NAME.mpd |
NewerOlder