Differences between revisions 1 and 4 (spanning 3 versions)
Revision 1 as of 2012-03-13 22:00:27
Size: 565
Editor: SamatJain
Comment:
Revision 4 as of 2012-04-22 20:43:53
Size: 1083
Editor: SamatJain
Comment:
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
== Rotate ==

If the camera was recording in "upside down" mode:

{{{#!highlight sh numbers=off
parallel -u 'echo {}; jpegtran -rotate 180 -perfect -copy all -outfile {}.tran {} && mv {}.tran {}' ::: *.jpg
}}}

== Resize & crop ==
Line 2: Line 12:
parallel -u 'echo {}; jpegtran -rotate 180 -perfect -copy all -outfile {}.tran {} && mv {}.tran {}' ::: *.jpg
Line 6: Line 14:
# or Crop bottom
find . -name '*JPG' -print0 | xargs -0 -P2 -n8 mogrify -crop 2592x1944+0-486 -resize 1920x1080
}}}
Line 7: Line 18:
# LDR tonemapping For the GoPro HD Hero 2:

{{{#!highlight sh
# Crop top
find . -name '*JPG' -print0 | xargs -0 -P2 -n8 mogrify -crop 3840x2880+0+720 -resize 1920x1080
}}}

== LDR tone mapping ==

{{{#!highlight sh numbers=off
Line 9: Line 29:
}}}
Line 10: Line 31:
mencoder mf://*.JPG -mf fps=15:type=jpg -ovc lavc -oac lavc -of lavf -lavfopts format=webm -lavcopts threads=4:acodec=vorbis:vcodec=libvpx -ffourcc VP80 -o output15.webm == Encode to WebM ==

{{{#!highlight sh numbers=off
mencoder mf://*.JPG -mf fps=15:type=jpg -ovc lavc -oac lavc -of lavf -lavfopts format=webm -lavcopts threads=4:acodec=vorbis:vcodec=libvpx -ffourcc VP80 -o $(basename $(pwd)).webm

Rotate

If the camera was recording in "upside down" mode:

parallel -u 'echo {}; jpegtran -rotate 180 -perfect -copy all -outfile {}.tran {} && mv {}.tran {}' ::: *.jpg

Resize & crop

   1 # Crop top
   2 find . -name '*JPG' -print0 | xargs -0 -P2 -n8 mogrify -crop 2592x1944+0+486 -resize 1920x1080
   3 # or Crop bottom
   4 find . -name '*JPG' -print0 | xargs -0 -P2 -n8 mogrify -crop 2592x1944+0-486 -resize 1920x1080

For the GoPro HD Hero 2:

   1 # Crop top
   2 find . -name '*JPG' -print0 | xargs -0 -P2 -n8 mogrify -crop 3840x2880+0+720 -resize 1920x1080

LDR tone mapping

parallel -u 'echo {}; ~/sys/tonemap/tonemapping ~/sys/tonemap/default.tnp {} {}.tonemapped && mv {}.tonemapped {}' ::: *.JPG

Encode to WebM

mencoder mf://*.JPG -mf fps=15:type=jpg -ovc lavc -oac lavc -of lavf -lavfopts format=webm -lavcopts threads=4:acodec=vorbis:vcodec=libvpx -ffourcc VP80 -o $(basename $(pwd)).webm

SamatsWiki: GoPro (last edited 2017-04-14 09:43:49 by SamatJain)