Skip to content

Instantly share code, notes, and snippets.

View FurnasAZ's full-sized avatar

Cade Furnas FurnasAZ

  • Phoenix, Arizona, United States
View GitHub Profile
@FurnasAZ
FurnasAZ / ArcMapLayersToLYRFiles.py
Created May 11, 2021 19:20 — forked from TheBryanMac/ArcMapLayersToLYRFiles.py
Iterate through an ArcMap MXD, and export all layers to LYR files.
#Name: ArcMap Layers to LYR Files with Python
#Author: Bryan McIntosh
#Description: Iterate through an ArcMap MXD, and export all layers to LYR files.
import arcpy, os
#Set the working directory to where the Python file is stored
cwd = os.getcwd()
#Set the location of the MXD file
mxdPath = os.path.join(cwd,"MyMap.mxd")
#Set the location to store LYR files
@FurnasAZ
FurnasAZ / ffmpeg_mkv_mp4_conversion.md
Created August 3, 2019 05:18 — forked from jamesmacwhite/ffmpeg_mkv_mp4_conversion.md
Easy way to convert MKV to MP4 with ffmpeg

Converting mkv to mp4 with ffmpeg

Essentially just copy the existing video and audio stream as is into a new container, no funny business!

The easiest way to "convert" MKV to MP4, is to copy the existing video and audio streams and place them into a new container. This avoids any encoding task and hence no quality will be lost, it is also a fairly quick process and requires very little CPU power. The main factor is disk read/write speed.

With ffmpeg this can be achieved with -c copy. Older examples may use -vcodec copy -acodec copy which does the same thing.

These examples assume ffmpeg is in your PATH. If not just substitute with the full path to your ffmpeg binary.

Single file conversion example