-
-
Save sandikodev/da724d8c1063f86d053096dacf0e4dcf to your computer and use it in GitHub Desktop.
Revisions
-
MichaelKreil revised this gist
Mar 11, 2016 . 1 changed file with 6 additions and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -21,4 +21,9 @@ ffmpeg -r 25 -i video.mp4 -sws_flags bilinear -pix_fmt rgb24 -vf "scale=40:ih*40 # ... and play it ffmpeg -re -i video.mov -f rawvideo -vcodec rawvideo -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 # Code is used in e.g. https://github.com/MichaelKreil/mateplay # convert video to gif by first generate a palette and then use it to generate gif: ffmpeg -i video.mov -vf "scale=40:ih*40/iw, crop=40:16,palettegen" -y palette.png ffmpeg -i video.mov -i palette.png -lavfi "scale=40:ih*40/iw, crop=40:16,fps=25[x]; [x][1:v] paletteuse" -y sequence2.gif -
MichaelKreil revised this gist
Feb 17, 2016 . 1 changed file with 5 additions and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -13,8 +13,12 @@ ffmpeg -re -f avfoundation -r 30 -s 1280x720 -i "0" -vf "scale=40:ih*40/iw, crop ffmpeg -re -f avfoundation -r 25 -i "1" -vf "crop=1200:480, scale=40:16, eq=1.5" -f rawvideo -vcodec rawvideo -sws_flags bilinear -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 # Mac normal ffmpeg -re -f avfoundation -r 25 -i "1" -vf "crop=600:240, scale=40:16, eq=1.5" -f rawvideo -vcodec rawvideo -sws_flags bilinear -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 # Linux ffmpeg -re -video_size 600x240 -f x11grab -r 25 -i :0.0+100,200 -vf "scale=40:16, eq=1.5" -f rawvideo -vcodec rawvideo -sws_flags bilinear -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337; # prepare video for matelight ... ffmpeg -r 25 -i video.mp4 -sws_flags bilinear -pix_fmt rgb24 -vf "scale=40:ih*40/iw, crop=40:16" -an -vcodec libx264 -crf 6 -preset veryslow video.mov # ... and play it ffmpeg -re -i video.mov -f rawvideo -vcodec rawvideo -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 # Code is used in e.g. https://github.com/MichaelKreil/mateplay -
MichaelKreil revised this gist
Feb 16, 2016 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -15,6 +15,6 @@ ffmpeg -re -f avfoundation -r 25 -i "1" -vf "crop=1200:480, scale=40:16, eq=1.5" ffmpeg -re -f avfoundation -r 25 -i "1" -vf "crop=600:240, scale=40:16, eq=1.5" -f rawvideo -vcodec rawvideo -sws_flags bilinear -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 # prepare video for matelight ... ffmpeg -r 25 -i video.mp4 -sws_flags bilinear -pix_fmt rgb24 -vf "scale=40:ih*40/iw, crop=40:16" -an -vcodec libx264 -crf 6 -preset veryslow video.mov # ... and play it ffmpeg -re -i video.mov -f rawvideo -vcodec rawvideo -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 -
MichaelKreil revised this gist
Feb 16, 2016 . 1 changed file with 6 additions and 6 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -1,20 +1,20 @@ # Stream a video ffmpeg -re -i video.avi -vf "scale=40:ih*40/iw, crop=40:16" -f rawvideo -vcodec rawvideo -sws_flags bilinear -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 # Loop a gif ffmpeg -re -ignore_loop 0 -i image.gif -vf "scale=40:ih*40/iw, crop=40:16" -f rawvideo -vcodec rawvideo -sws_flags bilinear -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 # Stream webcam # Mac ffmpeg -re -f avfoundation -r 30 -s 1280x720 -i "0" -vf "scale=40:ih*40/iw, crop=40:16, pp=autolevels:f, eq=1.5" -f rawvideo -vcodec rawvideo -sws_flags bilinear -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 # Stream screen center (for e.g. YouTube videos) # Mac retina ffmpeg -re -f avfoundation -r 25 -i "1" -vf "crop=1200:480, scale=40:16, eq=1.5" -f rawvideo -vcodec rawvideo -sws_flags bilinear -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 # Mac normal ffmpeg -re -f avfoundation -r 25 -i "1" -vf "crop=600:240, scale=40:16, eq=1.5" -f rawvideo -vcodec rawvideo -sws_flags bilinear -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 # prepare video for matelight ... ffmpeg -r 25 -i video.mp4 -sws_flags bilinear -pix_fmt rgb24 -vf "scale=40:ih*40/iw, crop=40:16" -an -vcodec libx264 -crf 12 -preset veryslow video.mov # ... and play it ffmpeg -re -i video.mov -f rawvideo -vcodec rawvideo -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 -
MichaelKreil revised this gist
Feb 16, 2016 . 1 changed file with 11 additions and 7 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -1,16 +1,20 @@ # Stream a video ffmpeg -re -i video.avi -vf "scale=40:ih*40/iw, crop=40:16" -f rawvideo -vcodec rawvideo -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 # Loop a gif ffmpeg -re -ignore_loop 0 -i image.gif -vf "scale=40:ih*40/iw, crop=40:16" -f rawvideo -vcodec rawvideo -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 # Stream webcam # Mac ffmpeg -re -f avfoundation -r 30 -s 1280x720 -i "0" -vf "scale=40:ih*40/iw, crop=40:16, pp=autolevels:f, eq=1.5" -f rawvideo -vcodec rawvideo -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 # Stream screen center (for e.g. YouTube videos) # Mac retina ffmpeg -re -f avfoundation -r 25 -i "1" -vf "crop=1200:480, scale=40:16, eq=1.5" -f rawvideo -vcodec rawvideo -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 # Mac normal ffmpeg -re -f avfoundation -r 25 -i "1" -vf "crop=600:240, scale=40:16, eq=1.5" -f rawvideo -vcodec rawvideo -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 # prepare video for matelight ... ffmpeg -r 25 -i video.mp4 -vf "scale=40:ih*40/iw, crop=40:16" -an -vcodec libx264 -crf 18 -preset veryslow video.mov # ... and play it ffmpeg -re -i video.mov -f rawvideo -vcodec rawvideo -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 -
MichaelKreil revised this gist
Feb 15, 2016 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -8,7 +8,7 @@ ffmpeg -re -ignore_loop 0 -i image.gif -vf "scale=40:ih*40/iw, crop=40:16" -f ra // Mac ffmpeg -re -f avfoundation -r 30 -s 1280x720 -i "0" -vf "scale=40:ih*40/iw, crop=40:16, pp=autolevels:f, eq=1.5" -f rawvideo -vcodec rawvideo -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 // Stream screen center (for e.g. YouTube videos) // Mac retina ffmpeg -re -f avfoundation -r 25 -i "1" -vf "crop=1200:480, scale=40:16, eq=1.5" -f rawvideo -vcodec rawvideo -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 // Mac normal -
MichaelKreil created this gist
Feb 15, 2016 .There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,16 @@ // Stream a video ffmpeg -re -i video.avi -vf "scale=40:ih*40/iw, crop=40:16" -f rawvideo -vcodec rawvideo -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 // Loop a gif ffmpeg -re -ignore_loop 0 -i image.gif -vf "scale=40:ih*40/iw, crop=40:16" -f rawvideo -vcodec rawvideo -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 // Stream webcam // Mac ffmpeg -re -f avfoundation -r 30 -s 1280x720 -i "0" -vf "scale=40:ih*40/iw, crop=40:16, pp=autolevels:f, eq=1.5" -f rawvideo -vcodec rawvideo -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 // Send screen center for e.g. YouTube videos // Mac retina ffmpeg -re -f avfoundation -r 25 -i "1" -vf "crop=1200:480, scale=40:16, eq=1.5" -f rawvideo -vcodec rawvideo -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337 // Mac normal ffmpeg -re -f avfoundation -r 25 -i "1" -vf "crop=600:240, scale=40:16, eq=1.5" -f rawvideo -vcodec rawvideo -pix_fmt rgb24 - > /dev/udp/matelight.cbrp3.c-base.org/1337