Skip to content

Instantly share code, notes, and snippets.

View JPEGtheDev's full-sized avatar

Jonathan Petz JPEGtheDev

  • Dallas, TX
  • 16:22 (UTC -05:00)
View GitHub Profile
@JPEGtheDev
JPEGtheDev / SDLInstall.sh
Last active September 16, 2021 03:41
Auto install SDL2 on a CentOS System
#!/bin/bash
if [[ $EUID -ne 0 ]]; then
echo "This script must be run as root"
exit 1
fi
cd /tmp
hg clone https://hg.libsdl.org/SDL SDL;
cd SDL;
mkdir build;
cd build;
/usr/bin/g++ -c "./camera.cpp" -O0 -Wall -std=c++11 -o ./Debug/camera.cpp.o -I.
/usr/bin/g++ -c "./main.cpp" -O0 -Wall -std=c++11 -o ./Debug/main.cpp.o -I.
/usr/bin/g++ -o ./Viewer @"Viewer.txt" -L. -std=c++11 -lSDL2 -lGL -lGLU -lm -lGLEW -lpng -lfreeimage
ffmpeg -y -r 60 -f image2 -i ./capture/%d.png -c:v libx264 -preset placebo -b:v 75185.7K -pass 1 -f mp4 /dev/null && ffmpeg -y -r 60 -f image2 -i ./capture/%d.png -c:v libx264 -preset placebo -b:v 75185.7K -pass 2 -f mp4 /dev/null && ffmpeg -y -r 60 -f image2 -i ./capture/%d.png -c:v libx264 -preset placebo -b:v 75185.7K -pass 3 -f mp4 /dev/null && ffmpeg -r 60 -f image2 -i ./capture/%d.png -c:v libx264 -preset placebo -b:v 75185.7K -pass 4 output.mp4
@JPEGtheDev
JPEGtheDev / keybase.md
Created March 20, 2016 05:40
keybase.md

Keybase proof

I hereby claim:

  • I am jpegthedev on github.
  • I am jpegthedev (https://keybase.io/jpegthedev) on keybase.
  • I have a public key ASA66mlqvThXkFuvpgLzOh9XZma-zSAJ--cnyuZ2cTVpPwo

To claim this, I am signing this object:

@JPEGtheDev
JPEGtheDev / imgRec.h
Last active January 15, 2018 20:42
Output Frames for GLUT
/*
add makePicture() after glutSwapBuffers()
the first string is the output folder, which must be created before you start the application, otherwise it errors out.
the next two integers are the screen size, x,y respectively.
if the image is flipped, set the boolean to true, it will change it back to.
this also requires C++, so please change your compiler to nvcc or g++ for compilation.