{"id":993,"date":"2019-07-08T21:40:35","date_gmt":"2019-07-09T04:40:35","guid":{"rendered":"http:\/\/www.mjblythe.com\/hacks\/?p=993"},"modified":"2022-01-04T12:17:31","modified_gmt":"2022-01-04T19:17:31","slug":"custom-hugin-pto-shortcut","status":"publish","type":"post","link":"http:\/\/www.mjblythe.com\/hacks\/2019\/07\/custom-hugin-pto-shortcut\/","title":{"rendered":"Custom Hugin PTO shortcut"},"content":{"rendered":"<p>Want to be able to select multiple photos in a panorama, then quickly kick off the Hugin auto-analysis for that grouping<\/p>\n<blockquote>\n<pre>&gt; cat ~\/bin\/my_pto_gen\n#!\/usr\/bin\/env ruby\n\noutput = IO.popen([\"pto_gen\", *ARGV])\noutput.readlines.each do |line|\n  if(line =~ \/Written output to (.*)\/)\n    system(\"PTBatcherGUI\", \"-a\", $1, \"-b\")\n  end\nend\n<\/pre>\n<\/blockquote>\n<blockquote><p><code>&gt; cat ~\/bin\/my_pto_gen.desktop<br \/>\n[Desktop Entry]<br \/>\nVersion=1.0<br \/>\nName=Custom Hugin PTO generator<br \/>\nComment=Initialise a Hugin panorama project from multiple photos &amp; run the assistant<br \/>\nExec=my_pto_gen %F<br \/>\nNoDisplay=true<br \/>\nIcon=hugin<br \/>\nTerminal=false<br \/>\nType=Application<br \/>\nCategories=Graphics;<br \/>\nMimeType=image\/tiff;image\/jpeg;<br \/>\nGenericName=Panorama project generator &amp; assistant<\/code><\/p><\/blockquote>\n<blockquote><p><code>desktop-file-install --dir=\/home\/matt\/.local\/share\/applications\/ \/home\/matt\/bin\/my_pto_gen.desktop<br \/>\nupdate-desktop-database \/home\/matt\/.local\/share\/applications\/<\/code><\/p><\/blockquote>\n","protected":false},"excerpt":{"rendered":"<p>Want to be able to select multiple photos in a panorama, then quickly kick off the Hugin auto-analysis for that grouping &gt; cat ~\/bin\/my_pto_gen #!\/usr\/bin\/env ruby output = IO.popen([&#8220;pto_gen&#8221;, *ARGV]) output.readlines.each do |line| if(line =~ \/Written output to (.*)\/) system(&#8220;PTBatcherGUI&#8221;, &#8220;-a&#8221;, $1, &#8220;-b&#8221;) end end &gt; cat ~\/bin\/my_pto_gen.desktop [Desktop Entry] Version=1.0 Name=Custom Hugin PTO generator [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[7,11,1],"tags":[],"class_list":["post-993","post","type-post","status-publish","format-standard","hentry","category-howto","category-linux","category-uncategorized"],"_links":{"self":[{"href":"http:\/\/www.mjblythe.com\/hacks\/wp-json\/wp\/v2\/posts\/993","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/www.mjblythe.com\/hacks\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.mjblythe.com\/hacks\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.mjblythe.com\/hacks\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.mjblythe.com\/hacks\/wp-json\/wp\/v2\/comments?post=993"}],"version-history":[{"count":3,"href":"http:\/\/www.mjblythe.com\/hacks\/wp-json\/wp\/v2\/posts\/993\/revisions"}],"predecessor-version":[{"id":1115,"href":"http:\/\/www.mjblythe.com\/hacks\/wp-json\/wp\/v2\/posts\/993\/revisions\/1115"}],"wp:attachment":[{"href":"http:\/\/www.mjblythe.com\/hacks\/wp-json\/wp\/v2\/media?parent=993"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.mjblythe.com\/hacks\/wp-json\/wp\/v2\/categories?post=993"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.mjblythe.com\/hacks\/wp-json\/wp\/v2\/tags?post=993"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}