Bit depth

Forum for discussion of narrow-bandwidth mechanical television

Moderators: Dave Moll, Andrew Davie, Steve Anderson

Bit depth

Postby Steve Anderson » Sat Jun 30, 2007 7:47 pm

I've been doing some thinking and experimentation regarding bit depth for digitally stored NBTV signals. For example Klass's and Vic's colour encoding method uses 00h to 6Fh values I believe, or 112 (decimal) values for the luminance channel which seems fine. Even 8-bit for the luminance might seem overkill, 00h to FFh (256 decimal).

The first picture below is 480x640 with an 8-bit depth, the second is with a 4-bit depth, contouring is visible on her cheek, the final one is with a 2-bit depth. Even though it's really course I still would know who it was if I had never seen the picture before, but it's not very nice. I used Tiff files so there are no compression artifacts.

No dithering has been used in these pictures, it's straight truncation.

The last two have been converted to the NBTV format of 32x48, the first is with a bit depth of 8-bits, the second with just 4-bits. You'll need some software to zoom in.

The interesting thing is there is not that much difference, I'm not suggesting we use 4-bit, don't worry! But with the limited resolution we have it's almost impossible to create contouring.

Where am I going with this? I'm not sure, thought I just might mention it and see what others have to say. What I have noticed is that six bits (64 decimal values) is where I start to notice the discrete levels on CRT displays, but it's only just. Five bits are clearly discernable.

Steve A.

I was hoping to upload these as .tif files, but for some reason I couldn't and .bmp isn't allowed. So I've had to resort to .gif. 16 Colours 640 is much better in .tif format for some reason.
Attachments
256 Colours 640.gif
256 Colours 640.gif (126.69 KiB) Viewed 11794 times
16 Colours 640.gif
16 Colours 640.gif (50.1 KiB) Viewed 11794 times
4 Colours 640.gif
4 Colours 640.gif (14.19 KiB) Viewed 11794 times
256 Colours 32.gif
256 Colours 32.gif (2.09 KiB) Viewed 11794 times
16 Colours 32.gif
16 Colours 32.gif (760 Bytes) Viewed 11794 times
User avatar
Steve Anderson
"Fester! Don't do that to 'Thing'"
 
Posts: 5382
Joined: Fri Mar 30, 2007 10:54 pm
Location: Bangkok, Thailand

Postby Viewmaster » Sat Jun 30, 2007 11:47 pm

I am reminded by your images of 4 bits that pictures on TV, which have been badly degraded to avoid recognition of a face, (by using ultra large pixels....low bits), that if one nearly closes ones eyes a moving degraded face becomes more recognisable. This will apply to NBTV too.
I wonder why this is so?
It is as though the brain remembers detail from a previous large pixel
and interprates this into a new one as the face moves and fills in missing detail which, when the eyes are fully open is not apparent.
Maybe we should all watch NBTV through partly closed eyes. :lol:
Albert.
User avatar
Viewmaster
Frankenstein was my uncle.
 
Posts: 1306
Joined: Fri Apr 06, 2007 4:50 am
Location: UK Midlands

Visual resolution under the infulence.

Postby Steve Anderson » Sun Jul 01, 2007 3:56 pm

Viewmaster wrote:Maybe we should all watch NBTV through partly closed eyes. :lol:
Albert.


Having imbibed a reasonable amout of alcohol will help with that!

I remember some years ago an Englishman and a Japanese guy trying to agree a contract in Kuala Lumpur. During the day they had an interpreter, but once they got into the hotel bar in the evening they conversed easily. My friend and I dubbed this language as "Inhibriatu".

For those in the UK who remember "Bill and Ben, the flower-pot men", it was like that. Yet they clearly understood each other!

Steve A.

..and no, I never got my wicked way with Little Weed!
Attachments
fm-3.jpg
fm-3.jpg (8.57 KiB) Viewed 11761 times
User avatar
Steve Anderson
"Fester! Don't do that to 'Thing'"
 
Posts: 5382
Joined: Fri Mar 30, 2007 10:54 pm
Location: Bangkok, Thailand

Postby Klaas Robers » Sun Jul 01, 2007 11:11 pm

I remember from my B+W TV time that B+W video signals might be quantized in 6 bits, as long as the sync was not taken in account. This was not visible on the screens. If you include the sync you should use 7 bits, if you also include PAL or NTSC colour subcarrier 8 bits were needed.

Contouring is only visible in rather large areas with slowly changing grey values. As NBTV has almost no large areas this might be less visible. In the horizontal direction it is masked by the line structure (which gives a kind of contouring any way) and in the vertical direction it is masked by the bandwidth limitation.

But it is remarkable how well the 4 bits contouring is visible (on my monitor) as well in the dark areas (left edge of the face) as in the bright areas (tip of the nose).

Steve, could you do an inverse gamma correction (square root) on the original girls face, then do the truncation and do a gamma correction (square) on the result? May be that you also could do a 6 bits truncation?
User avatar
Klaas Robers
"Gomez!", "Oh Morticia."
 
Posts: 1656
Joined: Wed Jan 24, 2007 8:42 pm
Location: Valkenswaard, the Netherlands

Postby Steve Anderson » Mon Jul 02, 2007 2:56 pm

Klaas Robers wrote:Steve, could you do an inverse gamma correction (square root) on the original girls face, then do the truncation and do a gamma correction (square) on the result? May be that you also could do a 6 bits truncation?


Here's two pictures that have been truncated in the same way. Without writing some software to undo then re-do the Gamma they are as per the ones before.

The first one is with is with 64 shades (6-bit), the second is with 32 shades (5-bit).

I'm amazed how good they look! I have checked and they do only contain the number of levels indicated. If you can please check I got it right.

Steve A.

If you zoom right in on the tip of the nose in the 32 level version you can see the contouring....

P.S. I eventually found Gamma adjustment for the pictures, but undoing it, reducing the bit depth, then re-applying it made very little visible difference.
Attachments
64 Colours 640.gif
64 Colours 640.gif (264.07 KiB) Viewed 11733 times
32 Colours 640.gif
32 Colours 640.gif (170.2 KiB) Viewed 11733 times
User avatar
Steve Anderson
"Fester! Don't do that to 'Thing'"
 
Posts: 5382
Joined: Fri Mar 30, 2007 10:54 pm
Location: Bangkok, Thailand

Postby AncientBrit » Mon Jul 02, 2007 11:06 pm

Steve,

I normally work 6 bit mono, but there's little improvement over 5 bit.

I was considering a variant on the 2 byte-word coding proposed for colour encoding.

Luminance Y only, 6 bits

U colour difference, 5 bits

V colour difference, 5 bits

Total = 16 bit, or 2 bytes.

Only problem is there is no room left for audio.....


Graham
AncientBrit
Green padded cells are quite homely.
 
Posts: 858
Joined: Mon Mar 26, 2007 10:15 pm
Location: Billericay, UK

Postby Steve Anderson » Mon Jul 02, 2007 11:55 pm

AncientBrit wrote:I was considering a variant on the 2 byte-word coding proposed for colour encoding.

Luminance Y only, 6 bits

U colour difference, 5 bits

V colour difference, 5 bits

Total = 16 bit, or 2 bytes.

Only problem is there is no room left for audio.....

Graham


This is exactly where I was heading...I was just taking a small step at a time, but you've leap-frogged me.

As for the audio, that's not a problem. I'll explain my thoughts later, I'm a bit pushed for time right now.

Steve A.
User avatar
Steve Anderson
"Fester! Don't do that to 'Thing'"
 
Posts: 5382
Joined: Fri Mar 30, 2007 10:54 pm
Location: Bangkok, Thailand

Postby Klaas Robers » Tue Jul 03, 2007 8:12 am

In the 32 grey steps I see contouring at the dark part of the cheek, close to the hair. This might be because the gamma correction is quadratic and not an exponential function (which is used in digital photography on Photo CD, as far as I know)

You redid the experiment that 6 bits is good enough. Only the difference between 5 and 4 is so remarkable large.

I think that Graham missed the right channel, that also has 16 bits for sound.

In the CCNC we wanted to have a Y signal that is comparable with th Y signal of the B+W CD's. This costed us 2 bits, so we needed to us the ARB trick, because Y, U and V couldn't be encoded simultaneously in the 16 bits of Left. If you skip that requirement, it could be done.
User avatar
Klaas Robers
"Gomez!", "Oh Morticia."
 
Posts: 1656
Joined: Wed Jan 24, 2007 8:42 pm
Location: Valkenswaard, the Netherlands

Postby Steve Anderson » Tue Jul 03, 2007 1:33 pm

Klaas Robers wrote:You redid the experiment that 6 bits is good enough. Only the difference between 5 and 4 is so remarkable large.

I think that Graham missed the right channel, that also has 16 bits for sound.


I have to admit that I was astonished with the difference between the four (16 levels) and five bit (32 levels) versions. You really have to look hard to see any artifacts, from six bits upwards (64 levels) I find it hard to see any difference at all without really zooming in and looking critically at the picture.

Now, here we're dealing with a still picture, I don't know how the eye might interpret low bit depth at low resolutions in a moving picture. I guess there's only one way to find out.

So, for the moment let's push aside the issue of 'standard levels' and cut to the chase. Whether it be an audio CD or a data file, in one channel we have 16 bits to play with. As Graham suggested we use the six most significant bits for luminance, the next five for one colour difference channel, and the last five for the other.

It is 'traditional' to sample the colour difference signals at a lower rate than the luminance channel, in our case it would be half, which is where the ARB concept is derived from.

However, with the limited resolution that NBTV has there would probably be a very visable impairment if the colour channels were arranged as such. The above suggestion gives equal bandwidth to all three channels and is still monochrome compatable. There will be very small, probably invisible, artifacts of the first colour difference channel on a monochorome display. I can't imagine that the second colour difference channel would cause any visible effects at all.

The other thing to consider is the coding of the colour difference channels. Both Graham and I have been referring to them as 'colour difference', as in three channels, Y (luminance), U/Pb (blue difference) and V/Pr (red difference).

The advantage of using colour difference signals as opposed to a R, G or B channel is that on most scenes they are of generally lower amplitude yielding less interference to a monochrome display. It's quite simple to do, a small bunch of op-amps, a collection of resistors and you're in business. It's exactly the same principle as used in the FM stereo system, where the baseband signal is the sum and the regenerated subcarrier carries the difference information.

So, where do we go from here?

First thing in my opinion is we dump the concept of 'standard levels' coming out of a CD player or sound card. As I have mentioned in a different thread, there is no standard (at least for domestic equipment).

Second is we use the entire gamut availible to us, that is use all bits to maximum effect.

Third, colour information is conveyed at the same rate as the luminance channel.

Gents, your thoughts?

Steve A.
User avatar
Steve Anderson
"Fester! Don't do that to 'Thing'"
 
Posts: 5382
Joined: Fri Mar 30, 2007 10:54 pm
Location: Bangkok, Thailand

Postby Stephen » Tue Jul 03, 2007 2:08 pm

Steve Anderson wrote:It is 'traditional' to sample the colour difference signals at a lower rate than the luminance channel, in our case it would be half, which is where the ARB concept is derived from.

However, with the limited resolution that NBTV has there would probably be a very visable impairment if the colour channels were arranged as such. The above suggestion gives equal bandwidth to all three channels and is still monochrome compatable. There will be very small, probably invisible, artifacts of the first colour difference channel on a monochorome display. I can't imagine that the second colour difference channel would cause any visible effects at all.
When I wrote the article about Mr. Baird's sequential detail system and came up with an alternate embodiment, it was begging for the three fast rate coarse detail frames to offer colour, with each coarse detail frame have one third the horizontal and vertical resolution of the fine detail monochrome frame. As an experiment, I superimposed three 10 by 17 pixel primary colour coarse detail frames over the 30 by 51 pixel monochrome fine detail frame and viewing at a distance wherein the monochrome fine detail frame appeared to be "sharp", the superimposed coarse and fine detail picture composite seemed to be about the same as a standard 30 by 51 pixel image with no reduced chrominance resolution.

Now, if you view at a closer distance, wherein the monochrome fine detail image is fuzzy, then everything falls apart. It gets down to image size and viewing distance. If you view a 2 by 3 cm image at a "normal" viewing distance of perhaps 50 cm, then colour pictures with a luminance channel that has one third the horizontal and vertical resolution looks fine. With a larger image or closer viewing distance you need to have more chrominance bandwidth.
Stephen
User avatar
Stephen
Anyone have a spare straightjacket?
 
Posts: 427
Joined: Fri Jan 26, 2007 7:00 am

Postby AncientBrit » Tue Jul 03, 2007 10:41 pm

For low bit depths it might be useful to add "dither" to reduce contouring.

Essentially adding in some random noise of 1 bit height.

(For authenticity the noise could come from the background noise of old gramphone records?)

Graham
AncientBrit
Green padded cells are quite homely.
 
Posts: 858
Joined: Mon Mar 26, 2007 10:15 pm
Location: Billericay, UK


Return to Mechanical NBTV

Who is online

Users browsing this forum: No registered users and 23 guests