Wölfischhttps://woelfisch.de/blog/2010-07-06T21:10:00+00:00Jörg's BlogImproving the small shoulder support2010-07-06T21:10:00+00:00o'wolfhttps://woelfisch.de/blog/author/owolfhttps://woelfisch.de/blog/improving-the-small-shoulder-support<p>Does anyone remember <a href="http://woelfisch.livejournal.com/102625.html">the shoulder unicycle</a>? It used to be just an aluminum bracket to rest against the shoulder. Very simple and very effective.</p><p>In the meantime, I have added an L-bracket with a hot shoe mount for a microphone holder and purchased a Swit LED camera light which comes with an adapter for Sony L series batteries that has to go somewhere. Time for some improvements. Now it's a <em>pimped shoulder unicycle</em>:</p><p><a href="http://img.woelfisch.de/shoulder-support/sm-shoulder-sup-update.jpg"><img height="221" src="http://img.woelfisch.de/sm-shoulder-sup-update.jpg" width="240"/></a></p><p>In retro-perspective I just could have bought a rail support. But where's the fun in that?</p>A small shoulder support2009-10-11T21:49:00+00:00o'wolfhttps://woelfisch.de/blog/author/owolfhttps://woelfisch.de/blog/a-small-shoulder-support<p>The <a href="http://woelfisch.livejournal.com/97448.html">large shoulder support</a> I built a while ago is really useful and I don't want to film without it anymore. However, it is also quite bulky and heavy, which means it is quite impractical to take it on air travel.</p><p>Thus, I built a very small one to rest against my shoulder, not on it. After <a href="http://users.livejournal.com/xanaeth/">Xan</a> <em>shoulder moped</em>, after my own <em>shoulder chopper</em>, let me present the <em>shoulder unicycle</em>:</p><p><a href="http://img.woelfisch.de/shoulder-support/sm-shoulder-sup.jpg"><img height="154" src="http://img.woelfisch.de/sm-shoulder-sup.jpg" width="240"/></a></p>Shoulder Support, rev 1.02009-06-11T21:57:00+00:00o'wolfhttps://woelfisch.de/blog/author/owolfhttps://woelfisch.de/blog/shoulder-support-rev-10<p>And here's the solution to my small puzzle. It has something to do with rods, indeed. In fact, it is my first attempt at building a should support for large video camera. It all starts with purchasing materials (notably, aluminium profiles, screws, bolts rivets and tools):</p><p><a href="http://img.woelfisch.de/shoulder-support/shoulder-sup-01.jpg"><img height="142" src="http://img.woelfisch.de/shoulder-sup-01.jpg" width="240"/></a></p><p>The first step is to cut all the aluminium profiles into nice, handy smaller parts so they are easier to dispose... Just kidding.</p><p><a href="http://img.woelfisch.de/shoulder-support/shoulder-sup-02.jpg"><img height="206" src="http://img.woelfisch.de/shoulder-sup-02.jpg" width="240"/></a></p><p>The main rails are 55 cm long, connected with the narrow plates to a rigid frame. The inner width of the frames is 10 cm. Within the frame, there are two adjustable sleds: one to carry the camera plate, one to place to shoulder on. These were constructed with the short rails and the wide plates. Here's everything marked and centre-punched:</p><p><a href="http://img.woelfisch.de/shoulder-support/shoulder-sup-03.jpg"><img height="190" src="http://img.woelfisch.de/shoulder-sup-03.jpg" width="240"/></a></p><p>How do I secure the sleds on the frame? The idea was to have one (for the shoulder sled) or two (for the camera sled) M6 hexagon-socket screws to clamp the sleds to the rails. Alas, the rails are only 1 mm thick, a thread would tear quite quickly. I purchased a couple of L-type weld nuts, drilled some holes</p><p><a href="http://img.woelfisch.de/shoulder-support/shoulder-sup-04.jpg"><img height="75" src="http://img.woelfisch.de/shoulder-sup-04.jpg" width="240"/></a></p><p>and riveted (is that a verb?) them to the rails that carry the plates of the sleds:</p><p><a href="http://img.woelfisch.de/shoulder-support/shoulder-sup-05.jpg"><img height="114" src="http://img.woelfisch.de/shoulder-sup-05.jpg" width="240"/></a><br/>(Never mind the machine screw I used for the photo)</p><p>The next picture shows the components with all holes drilled:</p><p><a href="http://img.woelfisch.de/shoulder-support/shoulder-sup-07.jpg"><img height="213" src="http://img.woelfisch.de/shoulder-sup-07.jpg" width="240"/></a><br/>(Yes, I forgot the screws for the shoulder sled in this photo...)</p><p>As security nuts are for one-time use only, I did a test assembly with normal ones:</p><p><a href="http://img.woelfisch.de/shoulder-support/shoulder-sup-08.jpg"><img height="211" src="http://img.woelfisch.de/shoulder-sup-08.jpg" width="240"/></a></p><p>It worked quite well, however to properly secure the camera sled I had to fasten the screws so far that the main rails bend outwards. Not good in the long run. But the tests revealed that the camera plate slides wide enough that the sled could remain in one location most of the time. Holes (slightly smaller than M6) in the rail locks the screws (and the sled) properly without stressing the rails too much. Another discovery was that the shoulder sled doesn't really has any benefit that way. I was having a hard time stabilizing the camera both with and without it. Adding a plate in front of the sled solved that issue. </p><p>The final assembly, with the additional plate in place:</p><p><a href="http://img.woelfisch.de/shoulder-support/shoulder-sup-09.jpg"><img height="75" src="http://img.woelfisch.de/shoulder-sup-09.jpg" width="240"/></a></p><p>Still missing are a shoulder pad, and the counter-weights to compensate for the weight of the camera. Holding 3 kg of camera at half-arm length is quite strenuous in the long run. The construction (with the correct counter weight) could easily support a Betacam camera, but unfortunately the frame is too wide for my significantly smaller camera. I'll probably build a smaller version of this support, but only after some experience with this version. For a first-time project it turned out quite well, I think.</p>Vacation video (pt 2)2009-05-18T18:58:00+00:00o'wolfhttps://woelfisch.de/blog/author/owolfhttps://woelfisch.de/blog/vacation-video-pt-2<p><div style="width: 30em"><em>I am constantly amazed at how easy it is to accomplish things in Linux once someone works out the process. DVD Authoring is a good example of this.<br/><div style="text-align: right">— Chris Stoddard, <a href="http://linuxgazette.net/issue83/stoddard.html">Linux Gazette #83</a></div></em></div></p><p>I beg to differ. But once you understand how it works, it is not hard to automate most of the annoying time consuming steps.</p><p>So I have this DVD Video compliant MPEG stream, but I'd like to have some menu. First of all, forget all the graphical frontends to dvdauthor. "Q" DVD Author sure looks nice and you can easily create rather complex menu structures, but it crashes often and there is no manual (just a bunch of more or less helpful tutorials.) It didn't fit my requirements, at least I wasn't able to define different pictures for highlighted and selected menu entries. You can define differently coloured borders or semi-transparent masks to overlay a picture, but I wanted to have a white icon turning yellow on highlight and grey on select.</p><p><img height="48" src="http://img.woelfisch.de/lj-dvdmenu-play-w.png" width="60"/> <img height="48" src="http://img.woelfisch.de/lj-dvdmenu-play-y.png" width="60"/> <img height="48" src="http://img.woelfisch.de/lj-dvdmenu-play-g.png" width="60"/> </p><p>I've also tried kdvdauth, gdvdauthor, and several more that were not able to properly design a menu the way I wanted it to behave. Okay, let's dig up one of the numerous tutorials from the lazyweb and do it manually.</p><p>Unfortunately, most of the tutorials don't explain why something is done a certain way. The first thing you need to know is that DVD menus are just regular MPEG audio/video tracks with subtitles, glued together with a rather simple scripting engine during authoring. That means that you just need to convert your background image to a video, encode audio, create two subtitle tracks containing the button overlays (one for highlighted buttons, one for selected, or clicked, buttons), and multiplex everything. Very simple, but with some limitations: the video has to be shorter than 30 seconds, it must have an audio substream (can be silence, though) and the button layer graphics can only have four colours at a time, including the background colour, as they are implemented as subtitle graphics.</p><p>Did I mention that it is crucial to understand that highlighting/selectable elements, also called buttons, are in fact subtitles? Okay, so here's the config file for spumux, a subtitle generator and mulitplexer:</p><p><pre><br><subpictures><br/><stream><br/><spu force="yes"<br/> start="00:00:00.00"<br/> select="mask-selected.png"<br/> highlight="mask-highlighted.png"<br/> autooutline="infer"<br/> autoorder="rows"/><br/></stream><br/></subpictures><br/></br></pre></p><p>Our mask layer images are <kbd>mask-selected.png</kbd> and <kbd>mask-highlighted.png</kbd>. These contain all the buttons, spumux will automatically try to detect their position and geometry and enumerate them. You tell <kbd>dvdauthor</kbd> what these do later.</p><p>Now comes the part that needs more thought. I have a video with 34 chapters and up to six chapters per menu. This results in 6 chapter menus, not counting the main menu. The chapter menus look like this:</p><p><img height="144" src="http://img.woelfisch.de/lj-dvdmenu-scenes1.png" style="border: 1px solid" width="180"> <img height="144" src="http://img.woelfisch.de/lj-dvdmenu-scenes2.png" style="border: 1px solid" width="180"> <img height="144" src="http://img.woelfisch.de/lj-dvdmenu-scenes6.png" style="border: 1px solid" width="180"/></img></img></p><p>It's a major PITA to align all the icons for each slide just by calculating their position, thus I did it with The Gimp and multiple layers:</p><p><table><tr><td><img height="144" src="http://img.woelfisch.de/lj-dvdmenu-background.png" style="border: 1px solid" width="180"/> <br/>Background</td><br><td><img height="144" src="http://img.woelfisch.de/lj-dvdmenu-deselected.png" style="border: 1px solid" width="180"/> <br/>Deselected</td><br><td><img height="144" src="http://img.woelfisch.de/lj-dvdmenu-highlighted.png" style="border: 1px solid" width="180"/> <br/>Highlighted</td><br><td><img height="144" src="http://img.woelfisch.de/lj-dvdmenu-selected.png" style="border: 1px solid" width="180"/> <br/>Selected</td></br></br></br></tr></table></p><p>The additional <em>Deselected</em> layer makes it easy to just replace the background image by keeping the graphical elements intact.</p><p>However, exporting single layers and converting them to two bit colour depth is more work than anticipated: every other layer except the one to be exported needs to be removed, otherwise The Gimp creates a palette from the colour information of all the layers... Uargh. And besides, what for do I have a computer? But as I already have layers, and the menu generator of Premiere Elements does something quite cool with Photoshop layers, why not re-implement that?</p><p>I was too lazy to read into The Gimp's scripting engine, and ImageMagick currently recognizes only two layers of an XCF file, so I downloaded and compiled <a href="http://henning.makholm.net/software">XCFTools</a> (thank you Wikipedia for the link!) which unfortunately isn't available from the openSUSE build service (yet). The tools do not require The Gimp's libraries and can convert from xcf to png or pnm.</p><p>With that in mind, I wrote the following script to convert an XCF file to DVD menu:</p><p><pre><br>#!/bin/sh<br/>menu="$1"</br></pre></p><p># Extract background and normal overlay<br/>xcf2png -o "$menu/background.png" "graphics/$menu.xcf" Background Deselected </p><p># Extract and convert highlight overlay<br/>xcf2pnm -a /dev/null "graphics/$menu.xcf" Highlighted | \<br/> convert pnm:- -fuzz 10% -transparent black -colors 2 "$menu/mask-highlighted.png"</p><p># Exctract and convert select overlay<br/>xcf2pnm -a /dev/null "graphics/$menu.xcf" Selected | \<br/> convert pnm:- -fuzz 10% -transparent black -colors 2 "$menu/mask-selected.png"</p><p># Convert the background to an MPEG2 video<br/>png2yuv -n 25 -I p -f 25 -j "$menu/background.png" | \<br/> mpeg2enc -F 3 -n n -f 8 -a 2 -o "$menu.m2v"</p><p># Adjust config file for subtitle / button layer<br/>sed "s:mask:$menu/mask:g" spumux.xml >"$menu/spumux.xml"</p><p># multiplex everything to a DVD stream<br/>mplex -f 8 -o /dev/stdout "$menu.m2v" silence.mp2 | \<br/> spumux -v 2 "$menu/spumux.xml" > "$menu/menu.mpg"</p><p># remove temporary video (you may want to remove the PNGs as well)<br/>rm "$menu.m2v"</p><p>The file <kbd>silence.mp2</kbd> is an MPEG1 L2 audio stream with... silence, of course. Replace with something else if you want audio for your menu, it just has to be MP2 or AC3 encoded. For <kbd>spumux.xml</kbd>, see above. The script takes one argument, the name of the menu. If you run it as "<kbd>./create-menu.sh myMenu</kbd>", it expects the gimp file at <kbd>graphics/myMenu.xcf</kbd> and will write the stream to <kbd>myMenu/menu.mpg</kbd>.</p><p>With The Gimp and a few lines of bash script it really becomes easy to design and author menus for video DVDs. But don't ask how long it took to actually research everything.</p><p>Finally, create a configuration file for dvdauthor (see one of those other tutorials for how to do it) and author the DVD.</p>Vacation video done, at last (pt 1)2009-05-16T22:49:00+00:00o'wolfhttps://woelfisch.de/blog/author/owolfhttps://woelfisch.de/blog/vacation-video-done-at-last-pt-1<p>In case you wondered why I didn't update my LJ for several weeks (and rarely said something on Twitter, either): I was busy editing last year's vacation video. I won't link it here, it is mostly personal stuff and the quality of the footage is rather poor, but it was a nice exercise to learn editing. As <a href="http://www.kdenlive.org">Kdenlive</a> still isn't suitable for such a large project (but progressing quite well currently,) I had to resort to a non-free editing solution. <a href="http://www.adobe.com/products/premiereel/">Adobe Premiere Elements</a> did the job amazingly well, at least I didn't miss any feature of the professional version. Granted, as a 32 bit application it runs out of memory quite often with such a comparatively large project, but I've seen much worse behaviour of much more expensive software. The movie had <s>more than 700</s> 774 clips on the time line in the end, and runs for 94 minutes.</p><p><img height="272" src="http://img.woelfisch.de/prel-screenshot.jpg" with="340"/></p><p>The built-in DVD menu generator is not so useful: You can only slightly modify the pre-defined templates, unless you peek around a bit in the file system and discover that those are actually multi-layered Photoshop project files. I purchased the bundle with Photoshop Elements, thus I was able to modify a template a bit more, however opposed to Premiere Elements, Photoshop Elements is lacking some crucial features like guard lines (you can see but not create or move them) and some effects aren't directly accessible (you can "copy" them from some existing project, though.) I ended up installing The Gimp on the Vista system for the other graphics needed.</p><p>PRE's built-in export modules for DVDs and H.264 are broken. This is one frame from the DVD <br/>generated by PRE:</p><p><img height="255" src="http://img.woelfisch.de/rt-dvd-artifact.jpg" width="340"/></p><p>The (animated) caption is wrong, here's a close-up:</p><p><img height="122" src="http://img.woelfisch.de/caption-artifact.jpg" width="240"/></p><p>The vertical black line next to the blue box is in any export via the "distribute" menu. A DV video export does not have this artifact:</p><p><img height="122" src="http://img.woelfisch.de/caption-dv.jpg" width="240"/></p><p>What now? Well, reboot to my usual openSUSE Linux desktop, grab some multimedia conversion tools from <a href="http://packman.links2linux.de">Packman</a> and convert the DV file with ffmpeg. Et voila:</p><p><img height="122" src="http://img.woelfisch.de/caption-fixed.jpg" width="240"/></p><p>Unfortunately, FFmpeg is currently <em>a bit</em> too restrictive regarding DV AVI files generated by Windows. I get literally thousands of messages like <em>AC EOB marker is absent pos=64</em>. This is being tracked as <a href="https://roundup.ffmpeg.org/roundup/ffmpeg/issue1060">issue 1060</a> by the FFmpeg issue tracker, but not resolved yet. Don't think that MPlayer's mencoder would do any better: it relies on FFmpeg for reading DV files. Additionally, it crashes before it could finish conversion. What now? Extracting video and audio with <em>tcdecode</em> from the <a href="http://www.transcoding.org/">transcode</a> package does work, but I wasn't able to multiplex the streams again, as the current version of ffmpeg seems to ignore <kbd>-itsoffset</kbd> and transcode insists on re-encoding the whole video...</p><p>A colleague mentioned <a href="http://fixounet.free.fr/avidemux/">Avidemux</a> a while ago, and indeed: it is able to rebuild the stream without re-encoding its content. It also is able to encode to other formats, so I had some well encoded MP4 files very quickly. And it can even create MPEG2 streams suitable for DVD authoring! Or so I thought. Well, the lavc encoder sure has excellent compression, and it looked very well on the computer screen. However, my DVD player didn't like the stream at all. Apparently, it swapped the half-pictures, despite using the correct options. Mplayer and vlc don't care about it (in fact, they don't even recognize that something is wrong), so I had to rebuild the track again with FFmpeg after I was done with the menus and mastered the first DVD. Ugh. Hint: use single pass encoding to check whether it works at all, and afterwards recreate the stream with two-pass encoding. But don't fix the chapter entry points before you've created the final stream, as the start of the GOPs will change and FFmpeg cannot place GOP starts at pre-defined times.</p><p><em>To be continued...</em></p>Broken Camera2009-04-06T21:12:00+00:00o'wolfhttps://woelfisch.de/blog/author/owolfhttps://woelfisch.de/blog/broken-camera<p>My old video camera died. Luckily, I bought a new and better one some weeks ago. But it is still a sobering experience to see 200-odd Euros worth of electronics turning into a useless brick shortly after warranty runs out. Even though the correct voltage can be measured at the test points, the camera doesn't do anything. No tape operation, no display, nothing.</p>