Live data from Hacker News

A Pixel Is Not A Little Square (1995) [pdf]

alvyray.com

61–70 of 81 posts

Re: A Pixel Is Not A Little Square (1995) [pdf]

#61
post #26

A pixel is a picture element. An element of a picture. Hence the name... It turns out that thinking of them as little boxes arranged in rectangular grids is very useful. Because that is how computers deal with them. Not as point samples. The article reminds me of the many mathematical text I've read insisting on that vectors are not tuples of numbers. That thinking of them as anything other than directions with magni…

> That thinking of them as anything other than directions with magnitudes is wrong.

Mathematicians like to think of just about everything as vectors, so that sentence seems a bit off.

Anyway, yeah, starting from abstract definitions is a great way to make a student's life hell. After all, there's a reason universities teach linear algebra twice.

Re: A Pixel Is Not A Little Square (1995) [pdf]

#62
post #26

A pixel is a picture element. An element of a picture. Hence the name... It turns out that thinking of them as little boxes arranged in rectangular grids is very useful. Because that is how computers deal with them. Not as point samples. The article reminds me of the many mathematical text I've read insisting on that vectors are not tuples of numbers. That thinking of them as anything other than directions with magni…

> When I teach graphics programming, I will continue to tell students that pixels are like little boxes.

There’s certainly a sweet spot, where too much theoretical background takes away from learning graphics, and too little could leave students unprepared, or worse, uninterested.

It’s certainly good & fun to go through at least a little sampling theory.

You might also be interested to know the guy who wrote this paper co-founded Pixar. His graphics advice is worth careful consideration.

> It turns out that thinking of them as little boxes arranged in rectangular grids is very useful.

Do keep in mind that the shape and the arrangement are two separate things. Alvy’s paper is talking about the sample shape, but not talking about the arrangement. The grid arrangement is useful, and Alvy would agree.

> Because that is how computers deal with them. Not as point samples.

I’d be cautious drawing that line. I realize you were talking in part about grid arrangements. But computers treat samples however we teach them to. It’s uncommon and unlikely you’re writing a lot of code that truly handles pixels as finite square geometry rather than a point sample. Plus, if you’re teaching things like magnification filtering using bilinear or bicubic, then you’re already treating pixels (or perhaps texels) as point samples.

Here’s what you get when you treat pixels as squares: https://news.ycombinator.com/item?id=17845460

Re: A Pixel Is Not A Little Square (1995) [pdf]

#63
post #45

The same is true for digital audio. We are so used to see the visual presentation of samples that look like a bar diagram, that a lot of people think analog sounds better because the curves are smoother. Chris Montgomery has a great talk about this.

https://xiph.org/video/vid2.shtml The talk https://youtu.be/cIQ9IXSUzuM I wish I could force any audiophiles to watch it before they waste their money on snake oil. I think a similar point can be made about analogue synthesis, e.g. You pay Moog £1500 for what is ultimately a fancy box for a relatively simple analogue circuit.

The problem is that most audiophile behaviour is driven by emotion and psychology, not by facts and evidence. In that respect it's perfectly analogous to religion—and we know how futile it is to challenge religious thinking with facts and evidence.

The underlying frustration is that objective (measurable) and subjective (unmeasurable) improvements in sound quality could ever be placed on equal footing with each other. It just wrecks my brain that people would ever spend a dollar on improvements that has an unmeasurable or negligibly measurable impact on the when there's still so much opportunity for substantial, measurable improvements.

If you want to improve your audio, focus on speakers, speaker placement, room acoustics, bass management and in-room calibration. Most everything else is relatively marginal (e.g. fancy amps, fancy DACs) or negligible/unmeasurable (e.g. fancy wires).

For most people with mid+ range audio gear, the number one upgrade they can perform is almost always to add targeted sound absorption to their room, not to change any of the electronics.

Re: A Pixel Is Not A Little Square (1995) [pdf]

#64

I wrote this on Quora several years ago, answering the questions of why pixels are square (and quickly clarified that I interpreted it as "why are they laid out on a rectangular grid?"): https://www.quora.com/Why-are-computer-pixels-square/answer/... The more I've thought about it since, the more I think we should represent images with hexagonal pixels (i.e., laid out on a hex grid), and that color images should trea…

You might want to look into pentile displays. You are correct in that they provide higher resolution than rectilinear displays (see the controversy tab in [1]), but they have largely fallen out of style because it is impossible to draw a straight line so everything looks blurry upon close inspection.

One cool trick is that you can sprinkle in more efficient white pixels to allow the display to reduce its power consumption.

[1] https://en.wikipedia.org/wiki/PenTile_matrix_family

Re: A Pixel Is Not A Little Square (1995) [pdf]

#65
post #14

Earlier quoted context omitted.

It sounds like you are talking about text that doesn't move. If you want a general filter that can give a result without visible aliasing while sacrificing as little sharpness as possible, a 2.2 gauss filter is very hard to beat and I have spent a lot of time trying. Box filters can be sharper, lancoz filters can be better for scaling down a final image, etc. but they will alias in a general sense. You might not see…

A Gaussian kernel will reduce ringing artifacts, but is much blurrier than alternative resampling kernels. https://www.imagemagick.org/Usage/filter/nicolas/ Does “diameter” here mean “twice the standard deviation”?

No, diameter means the width of the filter in pixels. Each side would extend 1.1 pixels for a 2.2 diameter filter.

If you compare filters at the same width, gauss will be softer, which is why you can lower the diameter.

Re: A Pixel Is Not A Little Square (1995) [pdf]

#67
post #65

Earlier quoted context omitted.

A Gaussian kernel will reduce ringing artifacts, but is much blurrier than alternative resampling kernels. https://www.imagemagick.org/Usage/filter/nicolas/ Does “diameter” here mean “twice the standard deviation”?

No, diameter means the width of the filter in pixels. Each side would extend 1.1 pixels for a 2.2 diameter filter. If you compare filters at the same width, gauss will be softer, which is why you can lower the diameter.

A Gaussian filter has infinite support, and is characterized by its variance (or standard deviation). https://en.wikipedia.org/wiki/Gaussian_filter

A ‘Gaussian’ which extends 1.1 units is a non-standard and not clearly defined thing. Are you picking some fraction of 1.1 as the standard deviation and truncating after? (Often Gaussian filters are truncated after 3 standard deviations, or similar.) Are you multiplying by some other window function? ...

Can you link to a more explicit formal description of what you mean?

Re: A Pixel Is Not A Little Square (1995) [pdf]

#68
post #34
post #26

A pixel is a picture element. An element of a picture. Hence the name... It turns out that thinking of them as little boxes arranged in rectangular grids is very useful. Because that is how computers deal with them. Not as point samples. The article reminds me of the many mathematical text I've read insisting on that vectors are not tuples of numbers. That thinking of them as anything other than directions with magni…

> The article reminds me of the many mathematical text I've read insisting on that vectors are not tuples of numbers. That thinking of them as anything other than directions with magnitudes is wrong. I break every mathematical object down into three things: 1. The intuition. Why do we have this concept to begin with? What underlying idea are we trying to capture? 2. The definition. These are the axioms. 3. The implem…

There's also the case that there's a bunch of vectors you _can't_ represent as tuples of numbers. A vector with orientation but a magnitude of 0 is a completely valid vector afaik, and you could do things with it like normalizing it to get a unit vector of the same orientation, and it's not representable as a tuple.

The tuple model is extremely useful, but incomplete.

Re: A Pixel Is Not A Little Square (1995) [pdf]

#69
post #43

However, image is not a wave. Sampling theorem applies beautifully to audio, but only to a limited degree to images. Some filters make sense in frequency domain, eyes are sensitive to certain frequencies more than others, but it all breaks down on hard edges, which don't behave like square waves. The problem is that in images the Gibb's effect is visible and annoying (ringing artifact). If sampling theorem applied, p…

This is mostly only true because our display technology lacks the resolution to reliably saturate the visual system in the same way that our audio technology does.

Re: A Pixel Is Not A Little Square (1995) [pdf]

#70
post #45

Earlier quoted context omitted.

https://xiph.org/video/vid2.shtml The talk https://youtu.be/cIQ9IXSUzuM I wish I could force any audiophiles to watch it before they waste their money on snake oil. I think a similar point can be made about analogue synthesis, e.g. You pay Moog £1500 for what is ultimately a fancy box for a relatively simple analogue circuit.

The problem is that most audiophile behaviour is driven by emotion and psychology, not by facts and evidence. In that respect it's perfectly analogous to religion—and we know how futile it is to challenge religious thinking with facts and evidence. The underlying frustration is that objective (measurable) and subjective (unmeasurable) improvements in sound quality could ever be placed on equal footing with each other…

I try to explain that to people. Even just the basics like fiddling with your EQ to your liking.

A lot of this analogue woo applies to synthesisers, as mentioned previously. For £500ish you can buy a million core, trillion transistor monster but for £1500 you get a box with some op amps and a (gasp) digital signal path in some cases.

Post reply on HN