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
| #!/bin/zsh | |
| index=0 | |
| for f in *(DN); | |
| do | |
| d=`date +%Y%d%m-%H%M%S` | |
| echo "Converting $f to $d.mp4" | |
| ffmpeg -i $f -vcodec h264 -acodec aac -strict -2 $d.mp4 | |
| ((++index)) | |
| done |
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
| #!/bin/bash | |
| files=./* | |
| index=0 | |
| for f in $files | |
| do | |
| d=`date +%Y%d%m-%H%M%S` | |
| echo "Converting $f to $d.mp4" | |
| ffmpeg -i $f -vcodec h264 -acodec aac -strict -2 $d.mp4 | |
| ((++index)) | |
| done |
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
| $path = $PSScriptRoot | |
| Write-Output "In directory: "$path | |
| $files = Get-ChildItem -Filter *.mp4 | |
| foreach ($file in $files) | |
| { | |
| $fileNameIn = $file.Name | |
| $date = get-date -format "yyyy-MM-dd-HHmmss" | |
| $fileNameOut = $date + ".mp4" | |
| Write-Output "Converting $fileNameIn to $fileNameOut" | |
| ffmpeg -i $fileNameIn -vcodec h264 -acodec aac -strict -2 $fileNameOut".mp4" |
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
| float4x4 GetRotationDir(float3 direction, float3 up = float3(0, 1, 0)) | |
| { | |
| float4x4 result; | |
| float3 xaxis = normalize(cross(up, direction)); | |
| float3 yaxis = normalize(cross(direction, xaxis)); | |
| result._11 = xaxis.x; | |
| result._12 = yaxis.x; | |
| result._13 = direction.x; | |
| result._14 = 0; |
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
| git filter-branch --force --index-filter \ | |
| 'git rm --cached --ignore-unmatch %1' \ | |
| --prune-empty --tag-name-filter cat -- --all |
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
| git filter-branch -f --prune-empty --tree-filter ' | |
| if [ -f .gitattributes ]; then | |
| git rm -f .gitattributes | |
| fi | |
| find * -type f | while read FILE; do | |
| while head -2 "$FILE" | grep -q "^oid sha256"; do | |
| ref=$(cat "$FILE") | |
| echo -n "$ref" | git lfs smudge > "$FILE" | |
| git add "$FILE" | |
| done |
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
| /[Ll]ibrary/ | |
| /[Tt]emp/ | |
| /[Oo]bj/ | |
| /[Bb]uild/ | |
| /[Bb]uilds/ | |
| /Assets/AssetStoreTools* | |
| # Visual Studio 2015 cache directory | |
| /.vs/ |
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
| # 3D models | |
| *.3dm filter=lfs diff=lfs merge=lfs -text | |
| *.3ds filter=lfs diff=lfs merge=lfs -text | |
| *.blend filter=lfs diff=lfs merge=lfs -text | |
| *.c4d filter=lfs diff=lfs merge=lfs -text | |
| *.collada filter=lfs diff=lfs merge=lfs -text | |
| *.dae filter=lfs diff=lfs merge=lfs -text | |
| *.dxf filter=lfs diff=lfs merge=lfs -text | |
| *.fbx filter=lfs diff=lfs merge=lfs -text | |
| *.jas filter=lfs diff=lfs merge=lfs -text |
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
| #!/bin/bash | |
| # mounts a volume over afp and syncs from local to mount | |
| # reads in computer, username and password as args | |
| # change {SYNC_FROM} and {SYNC_TO} | |
| while echo $1 | grep -q ^-; do | |
| eval $( echo $1 | sed 's/^-//' )=$2 | |
| shift | |
| shift |
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
| # convert mov to mp4 | |
| ffmpeg -i input.mov -vcodec h264 -acodec aac -strict -2 output.mp4 | |
| # convert and resize height (width will auto scale to match input dimensions) | |
| ffmpeg -i input.mov -vf scale=-1:height -vcodec h264 output.mp4 |