Skip to main content
Topic: Good 1bit-ADPCM codecs? (Read 5063 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Good 1bit-ADPCM codecs?

Hello,

it is a bit embarassing to ask this in a hifi forum, but:

What are the best 1-bit ADPCM codecs available for download?

I know, they all are noisy but I developed my own and want to compare the quality of mine with others, because it still sounds pretty "clear" using only one bit per sample^^.

I'm not sure if it worth to release it.

These 1-bit ADPCMs are hard to find in google :-(.
I found only one at GitHub but it did sound much worse at same quality.

Thank you very much.

- I abandoned this account since I didn't find a way to delete it -

Re: Good 1bit-ADPCM codecs?

Reply #1
I'm not sure I would call this a hifi forum. It is a digital audio/audio codecs forum.

Re: Good 1bit-ADPCM codecs?

Reply #2
Then I'm right here, because I'm developing one :-D.

I read "Audio Technology Enthusiast's Ressource", and I thought, this is more a HiFI forum. :))

- I abandoned this account since I didn't find a way to delete it -

Re: Good 1bit-ADPCM codecs?

Reply #3
Are there really any popular ones? I think most of them are proprietary video game codecs. I think 1-bit makes sense only in DSD.

Re: Good 1bit-ADPCM codecs?

Reply #4
I've said, it is not HiFi quality.
But in most cases, it performs similar to IMA and MS ADPCM if used in 2-bit mode.

It is old, but yesterday, I improved it a bit (just for fun).

But it can't keep on the same level as modern frequency transformation based codecs. It would loose in compare to Opus and Vorbis.

I originally made it many years ago to transform audio to pictures. These pictures were intended to be print on paper so you can save audio on paper^^. This was somewhere in the time of Windows 98. These papers worked similar to QR codes and you can scan them to get the audio files back. That technique needed heavy compression to get the paper sheets scannable. That isn't useful anymore since hard drives became bigger and bigger so I butchered this ancient project yesterday (but resqued this codec from it).

Today, it might be still useful for microprocessors, where resources are limited, because only integer addition and subtraction is needed to decode it. IMA and MS need more processing power to decode. ;D

I find the technique behind ADPCM codecs interesting so I made my own.  :D

It seems, no one ever wants to use any kind of ADPCM anymore, so I keep it for myself.
- I abandoned this account since I didn't find a way to delete it -

Re: Good 1bit-ADPCM codecs?

Reply #5
ADPCM is vaguely interesting. It may be worth sharing, if only for passing interest and nostalgia value.

Re: Good 1bit-ADPCM codecs?

Reply #6
OK so now things make more sense. So you want to make something like a QR code that each dot actually represents a bit of an ADPCM file. That would be extremely hard since there is pretty like zero room for improving 1bit. On the other hand, if you used a lossy/speech codec with extremely good resilience in errors or dropped packages you might achieve the same or better results. It also kinda matches with the idea I had a long time now of somehow modulating a lossy audio stream into a normal cassette tape, more like a DIY DCC tape that uses regular tapes. The key is the modulation method/technic that I haven't found yet, though I bet there is one out there.

Re: Good 1bit-ADPCM codecs?

Reply #7
You misunderstood it. ;)

The codec and the project, which uses it, already exists for years.

The question was: Does the quality of the codec worth to keep it (That is, what I need other similar codecs for)?

Now it isn't there anymore because it became useless and I scraped it, but kept the codec from it.  :D

But yes, the pixels represented the ADPCM samples.
- I abandoned this account since I didn't find a way to delete it -

Re: Good 1bit-ADPCM codecs?

Reply #8
Appendix, because I cannot edit my posts  :(

Here is a sample:

https://www.dropbox.com/s/1gpj3iakv6aqh0x/adpcm.zip?dl=0

The package contains a few seconds of the left channel from this song (https://modarchive.org/index.php?request=view_by_moduleid&query=59502) encoded (and decoded back) using the 1-bit ADPCM.

Annotations:
- Left channel only, because the source file is not mono compatible.
- I converted it to WAV using Audacity before doing the conversion. It is resampled to 48000Hz because there is no support for the original 44100Hz. It is in fact an 1.08-bit encoding.
- I abandoned this account since I didn't find a way to delete it -

Re: Good 1bit-ADPCM codecs?

Reply #9
That dropbox link seems to be dead; gives a link not found error. I would be interested in seeing how this sounds, ADPCM is interesting to me.


Re: Good 1bit-ADPCM codecs?

Reply #11
I tinkered around with my little codec baby once more... I was bored^^.

I made somewhat two-stream container from it. The first one is the ADPCM I already explained here. The other track contains the difference between the original and the encoded file compressed losslessly. Both together comes up to approx 640-800kbps. It is pretty high bit-rate but almost lossless, if both are mixed together during playback.

It is not true lossless, because it does not support 44100Hz, because the algorithm operates at 24000Hz or a multiple of that (48000, 96000, 144000, 192000). So you have to live with a (high quality SoX-)resampling to 48000Hz in case of 44100Hz. If the source is already one of the supported sample rates, it is exactly lossless. :D

Killer samples raising the bit-rate are everything that has to do with loudness-war (clipping, hypercompression, intersample-overs). Such rectangular-shaped sounds are hard to trace for the ADPCM part.

High dynamic ranges and uncompressed classical music (especially church organs, trumpets, flutes and violins) are resulting in lowest bit rates and a good sounding lossy part. The other extreme, heavy-metal, results in lower bitrates too.

The lossy stream that can be played alone. Then it is lossy and has a fixed bit rate. The lowest bit-rate for an acceptable lossy part is 192kbps for a stereo file. If 288kps or higher is used, the artifacts are inaudible to me using hifi headphones. There is no VBR for the lossy part yet. Supported bitrates for the lossy part are: 48kbps (poor), 96kbps, 144kbps, 192kbps, 240kbps, 288kbps, 336kbps, 384kbps, 432kbps, 480kbps... no upper limit. The safe choice for quality would be 336 or 384 I think. The residue that does not fit into the lossy stream with a given bit-rate goes into the difference-stream. As higher the bit-rate for the lossy part is chosen, the lower the bit-rate of the difference-part is.

If both streams are played together, it is lossless (compared to the 48000Hz-resampled input file).

Because the difference-stream that makes it lossless is optional, the same codec can be used as lossy and lossless codec. You can turn a lossless file into a lossy one by dropping the difference-stream.

The compression artifact of lossy playback is little crackle and rumble that sounds like a vinyl disc (so I'm already using it for myself for compressing digitalized vinyl records). The rumble is caused by the internal usage of some basic pre-emphasis that reduces the crackle in the mid-frequency-range - just like a record player^^.

The encoder is currently hard to use because a few encoding parameters aren't chosen automatically yet. Still not ready for average users^^.

As I understood, FLAC works similar like this but uses completely different algorithm for the lossy part^^.

It was just a fun-codec because I wanted to build my own one. But is that useful in some way? Does it worth to develop it to something that is easy to use and then to share that as a serious audio codec? The lossy part is still more inefficient than psychoacoustic codecs but doesn't sound ugly "bity" if set to low....
- I abandoned this account since I didn't find a way to delete it -

Re: Good 1bit-ADPCM codecs?

Reply #12
In the days of extreme storage and computing power limitations such codec would be a killer (Say NES, SNES and Gameboy PCM support) but now I don't see how it would be useful. But even then I have my doubts because all companies decided to go for 2-bits and up for their PCM based audio on their games so even if you pitched the codec to Nintendo in that case back in that time I doubt they would consider it. There has to be a reason they didn't bother with 1-bit ADPCM and went straight for 2 or 4 bit. Even Gameboy's rare case of PCM samples of games were using at least 2-bit ADPCM which was really well tuned but still sounded like crap.

Re: Good 1bit-ADPCM codecs?

Reply #13
Could you name the codecs for comparisation? :D
I'm not familiar with video games.

My codec can be run at more than one bit. Even at fractions like 1.5 bit. Theoretically, there is 0.5 bit which sounds really crappy.
- I abandoned this account since I didn't find a way to delete it -

Re: Good 1bit-ADPCM codecs?

Reply #14
The codecs are proprietary and really obscure with little documentation if any. kode54 is the person that might be able to help you on that.

Re: Good 1bit-ADPCM codecs?

Reply #15
I don't know what, if any, codecs are used for Game Boy, since those are likely as close to PCM as possible, since they're bit banging the PSG to output a pure 2 or 4 bit PCM stream over the volume register.

NES has 1 bit DPCM for many things, which as you can imagine, is not that great, but still sounded okay for the most part.

You may have some luck if you try to examine the old TrueVoice codec, which was pretty crap for its time. It was a 1 bit codec, but it probably didn't use ADPCM. It was also limited to 8000 Hz.

 

Re: Good 1bit-ADPCM codecs?

Reply #16
Sounds all terrible.  :(
These are made for limited CPU power and limited sound processors with limited PCM support so these aren't comparable at all because of different use case.

I encountered a codec named "WavPack" during my further research. I heard about that name a few times but I thought it is an old MP3-fork or something like this from the 90's so I never touched it. On a quick test, it produced similar quality on in 192kbps-384kbps range but doesn't support lower bit rates. And I'm not 100% sure if this is an ADPCM variant, even it produces ADPCM-like artifacts.

I won't publish my codec.

Another candidate for keeping in fun-developing and using for myself xD.

But thank you^^.
- I abandoned this account since I didn't find a way to delete it -

 
SimplePortal 1.0.0 RC1 © 2008-2018