HNHacker News
TopNewBestAskShowJobs

lcrs

166 karma · joined July 9, 2012

http://twitter.com/lwwwwwws
submissionscomments
lcrs··on Show HN: 123D Catch by AutoDesk – Create 3D scans of virtually any object
There's documentation of a method to achieve the same thing using free-ish software here: http://wedidstuff.heavyimage.com/index.php/2013/07/12/open-s...

Principally it uses VisualSFM and Meshlab, both of which came to life as testbeds for algorithm research but are now useful in their own right. By all accounts 123D Catch does an excellent job, but is quite rigid in its workflow. Apparently it uses the engine from Acute3D's considerably more expensive Smart3DCapture.

Sadly neither VisualSFM or 123D Catch are usable for commercial work because of license and copyright problems respectively.

lcrs··on How Gauss Taught Us the Best Way to Hold a Pizza Slice
A couple of years ago I got really interested in the shape of cooling towers after hanging out inside a couple of derelict ones. I couldn't find a solid answer as to why they are hyperboloids, and in fact not all of them are, but the most common explanations were:

1) the throat at the top could be the optimum shape for creating cooling via the Venturi effect

2) they can be built entirely with straight diagonal structural members, as each section of the Shukhov tower illustrates, but only the very earliest ones would have been made this way and they're certainly not any more

3) they were the only suitable shape that could be analysed on paper, before the advent of computer-based structural analysis

4) uniform structural stiffness with no particular points of failure, as in the above article

Even a thorough literature review from the period after some collapsed in storms was inconclusive... from the proceedings of the 5th International Symposium on Natural Draught Cooling Towers: http://books.google.com/books?id=6j5nuvAd44QC&pg=PA3

I highly recommend a look inside one, the acoustics and general enormity are quite something. Being inside an active one looks to be even more of something from these pictures: http://www.foantje.com/active-cooling-tower/

lcrs··on Homemade Speakers
I think what one might crudely call the "audiophile phase beef" is not about the comb-filtering that results from misalignment but the non-linear phase response of most crossovers, before the signal hits the air. Most act somewhat like an all-pass filter: a flat frequency response but varying delay across the frequency spectrum. This doesn't affect frequency sweeps or white noise, but results in impulses and clicks being smeared out in time or ringing a bit. The thought among some is that this is audible on percussion sounds, but experimental evidence is dubious as far as I can see. There are some references in the classic Douglas Self crossover book: http://books.google.co.uk/books?id=D9l6JWKKSzUC&lpg=SA2-PA14...

A similar argument which I think more people would agree with is that reflex-loading a speaker hurts the low-frequency group delay, the lack of which is one reason suggested for the supposed clarity of the classic NS10 monitor: http://www.soundonsound.com/sos/sep08/articles/yamahans10.ht...

lcrs··on Visualizing Photons in Motion at a Trillion FPS
Even cameras which vary speed during an unbroken shot automatically compensate so the exposure stays the same, but doing so has other interesting effects, depending how it's done:

a) Compensating with shutter so that the integration time is constant means the quality of motion blur changes during the ramp. For example a shot that starts at 24fps and ramps to 120fps keeping a shutter time of 1/240th would start out with really crisp-looking "skinny shutter" motion, and you might see flickering and strobing if there's much camera motion. The end of the ramp would have normal looking amounts of motion blur. If there are CRTs or fluorescent lights in shot they'd flicker at different rates throughout the ramp. It can be a dead giveaway that something's about to happen if a shot starts with really tight motion blur like that.

b) Compensating with lens aperture is much less common because the depth of field changes, but starting with everything in focus, the focus becomes much tighter with the background way out of focus at high speed. Reportedly, mechanical problems tend to manifest as the aperture overshooting its mark or bouncing back leading to brightness variations at the end of the ramp.

c) Compensating with ISO/gain is possible these days, which would avoid the above problems but would end up with a noisier image for the high-speed end.

Recent bullet time shots are either fully CG, shot with an array of cameras, or cheated by hanging everything on wires, but it's interesting to check if any of these things from the days of 16mm skate films with the classic hang-time dips are re-created :)

lcrs··on Red, Yellow, and Blue
I've heard two explanations for this. The first is that the longer wavelength "red"-ish receptors in our eyes are also excited by the frequencies of light at the other end of the visible spectrum, so shorter wavelengths than blue start to appear red again. Unfortunately the graph produced to back this up is usually that of the CIE colour matching functions, which do indeed have an obvious lump around purple, but are not derived from measurements. That lump was added to create a three-primary space which didn't require negative numbers to encode completely pure single-wavelength colours. That's a problem which otherwise crops up when you use three primaries based directly on measurements of the eye, because the three pigments in our eyes are not selective enough that a single wavelength only activates one receptor. Real measurements of the pigments don't really back up the idea of extra sensitivity to purple in the long-wavelength cones.

The second explanation (or suggestion, at least) is more psychological. In the distant past our eyes had only two colour receptors, and our brains measured the relative difference between the two, so we percieved colour on a one-dimensional line - e.g. more "warm" long wavelengths or more "cool" short wavelengths. At some point we evolved a third receptor, and our brains began processing this extra input as another perceptual axis orthogonal to the existing one, which could be described as purple/green against the original red/blue. Exploring this new 2D space results in a continuous rainbow around the edges.

lcrs··on Python, Pitch Shifting, and the Pianoputer
It does seem a bit funny to do it in two stages but it's the standard way... it might seem more natural if you were to do the resampling stage first - resample by a factor of 2x and you have the same sound but an octave lower and twice as slow, then a 50% time-stretch gives you the original duration but maintains the new pitch.

The phase vocoder does use an FFT on each window internally, so that it can ensure the phases remain continuous when everything is merged back together. There are variants that let you monkey around with the FFT coefficients before the merge, so you can pitch-shift that way, but I believe when you stitch it back together you end with with the exact same artifacts as the two-step way. I think people have concentrated on perfecting time-stretching since pitch-shifting can be derived from it.

The problem with doing an FFT on the entire length of the sample is that shifting all frequencies would then simply speed it up as well as changing the pitch ;) Chopping it up into bits is key to separating the fundamental frequencies that we percieve as the general "pitch" and all the time-varying harmonics that we percieve as "timbre".

edit: what is maybe a bit hackish is the crude resampling here - when going to the trouble of building a phase vocoder at least some linear interpolation might be appropriate rather than just dropping/repeating samples ;)

lcrs··on Python, Pitch Shifting, and the Pianoputer
You can absolutely tell a difference! Probably more so with synthesized sounds, which don't have natural pitch deviations or complex harmonics. The beating you hear in any even-tempered dyad other than an octave is really obvious with sine or square waves, presumably especially so with the sustained notes in a chorale :)
lcrs··on Harry Eng – Master Bottle Filler
e2 is fairly deranged. It's not your place to head for an informative read, and "encyclopedia" would definitely not be the right word, but it's great for ideas, stimulation, not-quite-sure-if-satire, unfinished short fiction, and link chains like "geometrical" > cannon defense patterns > transhumanism > The Broken God > a cloned kitten named "cc". I think of it like /b/ for bored grad students who are into Barthelme and Jeff Noon. One of the treasures of the internet, in my book :)
lcrs··on Explanation of 44.1 kHz CD sampling rate
At 25fps and 48Khz you rather neatly have 1920 samples per frame, which is coincidentally the width of an HD picture. At least I think it's a kind of a coincidence... I believe the number 1920 was derived from the 720 horizontal pixels of Rec. 709, which doubled give a 1440 pixel 4:3 picture and hence a 1920 pixel 16:9 picture.

The 48Khz rate used by everything apart from CDs also came from video standards according to http://www.tvtechnology.com/opinions/0087/digital-audio-samp...

Here's some more about the number-theory used in digital video, from 1990 during the standardisation of HD: http://www.poynton.com/papers/SMPTE_90_Magic_Numbers.html

lcrs··on Ask HN: What is the most difficult tech/dev challenge you ever solved?
Had many terabytes of footage shot of events that couldn't be recreated with cameras that turned out to have broken firmware. When reading out the sensor the ADC would get out of sync with the shift register, resulting in adjacent pixels merging into each other or being skipped in a different pattern on each frame. Resulted in appalling pictures. I figured out how to re-bayer the image, then using some frequency-domain magic on a picture interpolated from the green photosites only, determined the shifting pattern in various areas of the chip. We could then automatically gain individual pixels up and down and remove the effect, resulting in a perfect image. Went and saw the fnished film at the biggest cinema I could find and didn't spot a single pixel wrong. Dread to think what might have happened if I'd tried to fix it in a more traditional "just paint it out" manner...
lcrs··on Rendering Head in WebGL
Those SIGGRAPH talks, OCIO and Jeremy Selan's http://cinematiccolor.com have been a touchstone a while :) Thank you so much for the filmicgames link, that's exactly what I was curious about.

In return maybe I can offer the Academy's linear-to-display reference rendering transform, which is intended to replace the myriad of tonemapping LUTs currently used for film: https://github.com/ampas/aces-dev/blob/master/transforms/ctl...

lcrs··on Rendering Head in WebGL
The page header mentions "filmic tonemapping", I'd love to hear what that entailed in this case - is it a post-render 3D LUT as some games now do? I couldn't see anything from reading the source... I'm really interested in how we perceive quality of colour in CG renders, and how CG in movies which goes through a print film LUT is helped or harmed by the process.
lcrs··on PowerVR GR6500: Ray tracing is the future and the future is now
Raytracing may be conceptually the most natural but it's not always the best choice for a lot of these cases - displacement, motion blur, depth of field and anti-aliasing are still often handled much more quickly by micropolygon/scanline rendering even if the lighting and shading is raytraced. Hair and fur is pretty problematic with raytracing too.

That said, physically-based shading is massively easier to art-direct, even if the "front end" as it were of the renderer isn't naively tracing rays from the camera. There's a killer set of slides and notes documenting ILM and Sony's switch to PBR here: http://renderwonk.com/publications/s2010-shading-course/

lcrs··on Cheap Lights with Spherical Harmonics
There's another great application of spherical harmonics in (non-real-time) lighting, used by Weta for Avatar. Instead of precomputing the terms for a particular lighting setup as above, they use SH to store an environment map for every point on an object, including the effect of occluding geometry. This is independent of the camera and light positions. At render time it's then cheap to rotate the environment or move the lights, and still get correctly occluded diffuse lighting. They won a technical Academy award for it.

Easy-ish overview: https://www.fxguide.com/featured/the-science-of-spherical-ha...

SIGGRAPH 2010 paper, focusing more on the creation of the SH cache than it's use: http://dbonline.igroupnet.com/ACM.FT/1780000/1778774/037-pan...

Slides about same: http://wwwcg.in.tum.de/fileadmin/user_upload/Lehrstuehle/Leh...

lcrs··on All RGB colors in one image
The mapping is not one-to-one though - for example when S is 0, all values of H give the same resulting colour, and worse when V is zero both H and S are useless. So an image exploring the full HSV space should look different, probably with a lot more of the grayscale.

I too have misgivings about HSV, the discontinuities created when generating hue ramps being particularly cruel. Using a rotation about the luma axis in YCbCr space gives much smoother rainbows but sadly not ones which hit all six primaries and secondaries. It's frustrating problem that perceptually H, S and V or L are what we think of when specifying a colour, but mapping them smoothly to RGB displays is so tough.

lcrs··on Moon
I worked on the post-production of Moon, particularly the titles and the screens in the base and Gerty's face. Pretty humbling to have someone pay so much attention to what we did!

It's funny to hear about the Microstile/Eurostile differences - when we had to replace type that was on the real set we made new elements using Eurostile, so there are probably some inconsistencies.

The Bank Gothic/gradient fill/outline choice definitely haunted us for a while after - it was already a bit of a scifi poster trope but it's got out of control since. I've cringed a few times seeing posters on the tube and wished we'd picked something slightly different. I remember being keen on an outlandish faux-Cyrillic face at the time but it wasn't legible enough. I did win the argument about colour though - my boss at the time did a bunch of concept frames with translucent orange type for the main credit lines... there's a little interview with him here: http://www.artofthetitle.com/title/moon/

Maybe it's too obvious to bear mentioning but there's a big foreshadowing in the shot where Sam Rockwell's credit appears - a second copy of his name dissolves up out of focus further back inside the base...

The OCR-1A type was set by me, in a slight hurry as I recall, type-on effect and all. It had to look different to the Bank Gothic credit lines, and I'm sure we tried the obvious Eurostile and it wasn't readable or was too heavy for that amount of text. It feels a bit of a case of too many faces in succession, in retrospect. I love machine-specific typefaces. I think I first got into them after reading The Computer Contradictionary, which mentions E13B a couple of times, the type used for the numbers printed in magnetic ink on cheques: http://en.wikipedia.org/wiki/Magnetic_ink_character_recognit.... That book is worth a look if you appreciate a bit of cynical tech humour... http://books.google.co.uk/books?id=tZKCZje8178C&printsec=fro...

The dot-matrix background on the text fields of the "big board" with the countdown on it was probably my bad also... we replaced that whole board wherever it appears in the film because the real prop had light leaking into the four harvester status lines and you could see they were acetate. We definitely tried having the letters formed by the actual dots but they weren't legible enough, and making the dots smaller made them not legible enough. Sense of nerd embarrassment. I guess it's some kind of future display technology with... big dots? Err...

Trivia: the postcard reading "wish you were here" was inserted in post because we had to cover up the real one which couldn't have its rights cleared ;)

More trivia: there was a spelling mistake on one of the panels on set, the one which says "satellite uplink" when Matt Berry is yelling at Gerty. It was caught by QC and I have some memory of fixing it for that shot since we'd inserted the video into that screen anyway, but it might be visible in other shots. It had "satellite" spelled "satelite".

Looking forward to more from that blog. I've thought of starting something similarly one-track, favourites being "over-obvious ND grad filters in film" or "non-circular lens vignettes done badly in post through the ages" or "10 worst skies graded without highlight rolloff" ^_^

lcrs··on Moon
I remember hearing at the time that the reason they were able to build such a big set for the moon base was because the stages were mostly empty, also due to the writers' strike.
lcrs··on Installing VLC Media Player voids your speaker warranty
I was always taught the opposite rule for PA amps - they should be rated higher than the speakers, as per http://books.google.co.uk/books?id=dWILAAAAQBAJ&pg=PA118&dq=..., http://www.sweetwater.com/insync/power-amp-buying-guide/#mat... or similar. The reasoning being that a lower power amp would have to run flat out, and clip, which pushes a lot of energy into the HF drivers. Safer for the tweeters to have a more powerful amp which is not run into clipping, even if some peaks exceed the cabinet's rated power.

The VLC volume control has always terrified me, I wish it would have AGC or at least a soft limiter when pushed above 100%. I've seen people watch films with it cranked up to 200% and the system volume turned down to compensate :(

lcrs··on If you move your mouse continually the query may not fail. Do not stop moving
I recently came across similar behaviour in Linux - if you are waiting in XNextEvent on one thread and you call glXSwapBuffers on another, it never returns. If you move the mouse, XNextEvent returns with a MotionNotify event and glXSwapBuffers can grab some internal X11 lock and complete. It then gets stuck on the next frame. The result is that you have to keep moving the mouse or nothing is drawn.

X11 is supposed to be multithreaded enough to allow this and it worked fine on older versions of Xlib, before the libxcb transition.

Fixed by using select() in the event loop for the curious: https://github.com/lcrs/6ilk/commit/d5c39abde09e0467a8a4d17d...

lcrs··on Dell Ultra Sharp 24" 4K display
No display of any kind meets the Rec. 2020 gamut spec. It's more a future proofing step than a realistic target. The fact that the primaries are sat right on the single-wavelength line indicates an eye towards future laser projectors though - the gory details of how the decisions were made start at page 27 of http://www.itu.int/dms_pub/itu-r/opb/rep/R-REP-BT.2246-2-201...
lcrs··on Lightpack – Ambient backlight for your displays
These actually increase the apparent contrast you see on the screen. They're especially helpful for LCD panels which have washed-out and uneven black which is very noticeable in a dark room. Having the colours match the picture seems largely a gimmick to me, but having a light surround makes the screen appear "darker". The exact effect it has is hard to measure, and attempts have been ongoing since the 50s. Here's a recent paper: http://www.scopecalc.com/image-contrast-and-surround-illumin...

There are SMPTE specs for exactly how much of what colour light should be used, and we follow them at work, but at home a string of LED fairy lights behind the screen helps a lot ;)

lcrs··on Linux ate my RAM
I do this a lot, on machines which are annoyingly vendor-tweaked to allow a lot of dirty pages. Copying files to USB sticks happens instantly, but the unmount then takes an age - like, 20 minutes. This is a way to get a measure of the progress of the unmount. I generally have a sleep in there as well though ;)
lcrs··on Optimizing Gaussian blurs on a mobile GPU
I've used a triangular ("conical"?) kernel when in a hurry and it looked reasonable. Vastly better than a box blur, at least. They're actually not separable but one can pretend and just do horizontal and vertical passes without much damage.

Amusingly Autodesk ship a GLSL shader with Flame which uses a triangular kernel under the hood but labels the button in the interface "Gaussian", the cheeky swines...

The nicest option to imitate lens blur is a circular kernel but that's quite aggressively non-separable. The other thing that really helps is blurring linear-light values instead of the usual gamma-encoded images. The blurs in Windows 7's Aero themes very clearly don't do this, to my eye - dark lines spread out too much and look generally muddy.

VFX guy who loves to blur things here :)

lcrs··on Optimizing Gaussian blurs on a mobile GPU
Last I played with FFT convolution it didn't end up being a win for any sane filter size, even compared to brute-force convolution with arbitrary non-separable kernels. Admittedly I was using off-the-shelf tools in Nuke, but I would imagine both their FFT and Convolve nodes are reasonably optimized.

There's an analysis of the 1D case here with some interesting cautions at the end: http://www.engineeringproductivitytools.com/stuff/T0001/PT15...

lcrs··on My Final Post
They make 2k and 4k chips, but only for their licensees I believe, not the public: http://www.dlp.com/technology/dlp-press-releases/press-relea...
lcrs··on My Final Post
I think the bits of negativity are more about their methods than their products. There aren't many people who find much to fault in the actual cameras, but the way they are marketed and supported is maddening to people used to dealing with the older-school cinema companies like Arri and Panavision.

The attitude is even evident in this last post:

"In 2005, I could see that the powers that be (Sony, Arri, Panavision) were going to attempt to persuade the film industry that 1080P was going to be the digital replacement for film." - for fifteen years years people have been aware that 4k was a sensible equivalent resolution. The first digitally restored film was done at 4k in 1993! The Panavision Genesis (with a Sony sensor) had a 6k horizontal sensor pixel count! The Arri D20 had a 2.8k sensor!

"Sony's digital cinema cameras were $200k+" - cinema cameras are always rented, not bought. Very few people care or even know about their list price. At the time it was bizarre to market a camera like this to the public rather than to rental houses.

"The only way we could do that was through incredible compression technology" - they use JPEG2000. Not even something more specialised like CineForm, which already existed.

"I should mention here that there were many color science and feature upgrades... for free. Again, what company ever offered that?" - cameras rented from a rental house have always had regular firmware upgrades, doing the kind of things Red's upgrades did.

Compare the technical documentation from Red to that of Arri - Arri will shower you with whitepapers full of numbers and graphs, and tell you exactly what is going on in their cameras. The Red colour science is still secret. What are the primaries of the sensor? It's secret. What do the F-LUT controls do? It's secret.

Enough moaning. Red were the first cinema company with a real marketing budget and it was all very strange to people who were all about the right tool for the job, most of those tools being made in limited runs in extremely practical packaging without shiny logos on every corner...

lcrs··on My Final Post
Geoff Boyle is probably more a commercials DoP than a feature film one, but in this context he is notable for running the CML mailing list, which is a pretty incredible resource for cinematographers. I think it's the most focussed, knowledgeable online community I've ever known. It's so on-point that you can buy a physical book of the discussions.
lcrs··on My Final Post
I'm not sure the Alexa and F35 were panicked responses to the Red... the Arri D20 and Panavision Genesis predated the Red, and are very clearly the ancestors of the Alexa and F35 respectively - they use the same resolutions, sensor layouts and colourspaces, if not the exact same chips and recording formats. Not to mention the Dalsa Origin, a 4k camera out well before the Reds.
lcrs··on Scientific Breakthrough Lets SnappyCam App Take 20 Full-Res Photos Per Second
Re video's "studio swing" dynamic range, the YUV components do have a different encoding range to those in JPEG, but if you expand them back out to 0-255 the image is in fact the same - you lose a lil' fraction of your bit-depth but no dynamic range.

I think you definitely made the right choice though - it's interesting that the obvious delta-coding and motion compensation tricks to reduce bandwidth are rarely used for video acquisition apart from the most limited devices like phones, stills cameras and the GoPro. Everything that can afford to uses per-frame coding like ProRes, REDCODE, AVC-Intra, DNxHD, Cineform... being able to seek quickly is important!

In fact Canon's 1DC 4k camera uses (dun dun duhhhhh...) motion JPEG :)

lcrs··on Illegally climbing the Golden Gate bridge at dawn (2011)
There's a lovely little book by John Law which includes climbing this bridge, back in the 70s: http://www.furnacepress.com/publications/law.html
← PreviousPage 2 of 3Next →