# Bits Per Sample / Sample Size (16-bit, 24-bit) Tag?

**URL:** https://community.mp3tag.de/t/bits-per-sample-sample-size-16-bit-24-bit-tag/14831
**Category:** General Discussion
**Created:** [June 22, 2013, 10:54pm UTC](https://community.mp3tag.de/t/bits-per-sample-sample-size-16-bit-24-bit-tag/14831 "2013-06-22T22:54:47Z")
**Posts on this page:** 12
**Page:** 1

<div class="post-metadata">

### Author: ![lonelon2000](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/l/e99b99/32.png) [@lonelon2000](https://community.mp3tag.de/u/lonelon2000)
#### Post date: [June 22, 2013, 10:54pm UTC](https://community.mp3tag.de/t/bits-per-sample-sample-size-16-bit-24-bit-tag/14831/1 "2013-06-22T22:54:47Z")

</div>

FLAC. WAV. DSD. DFF. APE... ![:music:](https://community.mp3tag.de/uploads/default/original/1X/2ba05d1ade5eb0d15fc173be6f717dbe63890a70.gif ":music:")

Basically any lossless format has the ability to have sample sizes (or bits per sample) that are greater than 16 bits.

Is there any way to include this informational tag within MP3Tag? We've been teased by the "Bits" column with the default column value of %\_BitsPerSample%, hoping that we can differentiate files using this tag, but it does not work. I am finding higher quality files at every turn ([www.HDTracks.com](http://www.HDTracks.com) is a good place to start), and I would love to rename files with this information included, but I can't rename them if they have the same samplerate (let's say 88.2Hz), but different samplesizes (16-bit vs. 24-bit) and are of the same format (FLAC)... they will essentially have the same filename when doing a "Tag \> Filename" conversion.

Programs like WinAMP and VLC can detect this information, it would be absolutely wonderful if the same could be said of MP3Tag... can this please be included as a feature - if not for all or most lossless formats, at least for FLAC, because I believe that ultimately that you can re-encode most of the lossless formats to FLAC.

---

<div class="post-metadata">

### Author: ![JJ\_Johnson](https://community.mp3tag.de/user_avatar/community.mp3tag.de/jj_johnson/32/67_2.png) [@JJ\_Johnson](https://community.mp3tag.de/u/JJ_Johnson)
#### Post date: [June 22, 2013, 11:31pm UTC](https://community.mp3tag.de/t/bits-per-sample-sample-size-16-bit-24-bit-tag/14831/2 "2013-06-22T23:31:59Z")

</div>

You had a default column defined to show %\_bitspersample%? Or is that something you tried, hoping it might work? I don't see it in the documentation.

But I agree 100%. I have never understood why this was omitted from Mp3tag.

---

<div class="post-metadata">

### Author: ![lonelon2000](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/l/e99b99/32.png) [@lonelon2000](https://community.mp3tag.de/u/lonelon2000)
#### Post date: [June 27, 2013, 9:26am UTC](https://community.mp3tag.de/t/bits-per-sample-sample-size-16-bit-24-bit-tag/14831/3 "2013-06-27T09:26:09Z")

</div>

My apologizes, I remember seeing it in a post somewhere on the internet a LONG time ago, and I had created the column, but it does not work. It is not a default column.

I've spent a lot of time (since 2008) doing a lot of scripting for filename conversions over the years using this tool. This feature would make MP3Tag even MORE awesome than it already is!

---

<div class="post-metadata">

### Author: ![i\_edgars](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/i/f475e1/32.png) [@i\_edgars](https://community.mp3tag.de/u/i_edgars)
#### Post date: [June 27, 2013, 5:22pm UTC](https://community.mp3tag.de/t/bits-per-sample-sample-size-16-bit-24-bit-tag/14831/4 "2013-06-27T17:22:01Z")

</div>

Can be do Mp3Tag program incorporated in both the number of Channels (1 or 2) and Bits per sample (16, 24, 32), so that it is visible in WinAmp view file info?

---

<div class="post-metadata">

### Author: ![lonelon2000](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/l/e99b99/32.png) [@lonelon2000](https://community.mp3tag.de/u/lonelon2000)
#### Post date: [July 10, 2013, 5:45pm UTC](https://community.mp3tag.de/t/bits-per-sample-sample-size-16-bit-24-bit-tag/14831/5 "2013-07-10T17:45:34Z")

</div>

Well, I've found a way to retrieve the "bits per sample" information using dbpoweramp's scripting functions. ![:music:](https://community.mp3tag.de/uploads/default/original/1X/2ba05d1ade5eb0d15fc173be6f717dbe63890a70.gif ":music:") BTW, dbPowerAmp is not free. I'm a proud owner of a registered copy, simply because I use the CLI as a tool within MP3Tag to convert other lossless files to FLAC, and convert FLAC files to 320kb MP3s bringing over all of the tags, including the album art. It's a tool that I can't live without... just like MP3Tag. 😃 ![:music:](https://community.mp3tag.de/uploads/default/original/1X/2ba05d1ade5eb0d15fc173be6f717dbe63890a70.gif ":music:")

Here's a link to the dbPowerAmp scripting page, if anyone is interested:

[http://dbpoweramp.com/developer-scripting-dmc.htm](http://dbpoweramp.com/developer-scripting-dmc.htm)

There are some nice methods that you can use to pull information for audio files in various formats once a new "dMCScripting.Converter" object is created (which I've managed to do in PowerShell) .

.AudioProperties  
.ReadIDTagElementValue

I'll post some information later that I've been able to pull from various audio files in multiple formats and settings to help me with testing and formatting a new filename string, which I've been able to convert from one of my custom "Tag \> FileName" scripts in MP3Tag - into PowerShell.

Since it is external to MP3Tag, I'll have to try to finish coding a PowerShell script (mostly done) and configure it as a tool in MP3Tag (which I haven't attempted yet) to rename the file (leaving it in the current directory that MP3Tag has open), and then manually refresh the directory. I should then be able to see the renamed file in MP3Tag, and then rename (move) the file again to place it in the correct directory, so I can still see it in MP3Tag. For the most part, if the file is encoded in anything other than 16-bit @ 44.1kHz stereo - it will appear in the filename, among other things.

To get an idea of what it does, here is some pseudocode:

```
%track%_%bitrate% - %title% - [%samplebits%-%samplerate%_%channels% - %minutes%.%seconds%]

```

No - it's not pretty, but this could be a possible workaround until this gets into MP3Tag. Someday. 🙂

---

<div class="post-metadata">

### Author: ![lonelon2000](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/l/e99b99/32.png) [@lonelon2000](https://community.mp3tag.de/u/lonelon2000)
#### Post date: [July 11, 2013, 7:32pm UTC](https://community.mp3tag.de/t/bits-per-sample-sample-size-16-bit-24-bit-tag/14831/6 "2013-07-11T19:32:30Z")

</div>

Like I promised, after parsing out the data from the output using dbPowerAmp, here are some of the AudioProperties from a FLAC file:

1. TYPE: Free Lossless Audio Codec File [.flac]
2. SIZE: 130.52 MB (37% Compressed)
3. LENGTH: 6 minutes 15 seconds
4. CHANNELS: 2 (stereo)
5. SAMPLE RATE: 96 KHz  
**6. SAMPLE SIZE: 24 bit**
6. BIT RATE: 4,608 kbps (DVD)
7. AUDIO QUALITY: Perfect (Lossless)
8. ENCODER: FLAC reference libFLAC 1.2.1 20070917
9. CONTAINS: Album Art, CRC, ID Tag [Vorbis Comments]
10. ARTIST: 
11. TITLE: 
12. ALBUM: 
13. TRACK: 01
14. YEAR: 1982
15. GENRE: R&B
16. ALBUM ARTIST: 
17. COMPOSER: 

Next is tag information from that same file:

1. TITLE: 
2. ALBUM: 
3. ARTIST:
4. GENRE: 
5. COMPOSER: 
6. YEAR: 1982
7. TRACK: 01
8. ALBUM ARTIST: 

Ok - so I left out some of the actual data and tags... but you get the picture 🙂

I've readied the PowerShell script and it runs perfectly using the following format in a 64-bit command prompt. It pulls the tags and information from the file, parses it and renames the file with a new file name according to the script in the same folder.

However, when I set it up as a tool in MP3Tag passing the complete filepath as an argument, I can see where the argument it passed to the script from a batch file, but the COM objects won't load. I'm thinking that this is a 64-bit vs 32-bit issue, where the 64-bit dbPowerAmp scripting dll won't register in a 32-bit command prompt.

Still trying to work out the kinks on this one, I'll let you guys know more details... when and if I can get this to work. All for the sake of including the Sample Size in a file name. 😃 ![:w00t:](https://community.mp3tag.de/uploads/default/original/1X/cb01eca72fe9339ff6f3ec9f1e3c5fe002be0f0a.gif ":w00t:")

![:music:](https://community.mp3tag.de/uploads/default/original/1X/2ba05d1ade5eb0d15fc173be6f717dbe63890a70.gif ":music:")

---

<div class="post-metadata">

### Author: ![dano](https://community.mp3tag.de/user_avatar/community.mp3tag.de/dano/32/6_2.png) [@dano](https://community.mp3tag.de/u/dano)
#### Post date: [July 13, 2013, 6:42am UTC](https://community.mp3tag.de/t/bits-per-sample-sample-size-16-bit-24-bit-tag/14831/7 "2013-07-13T06:42:11Z")

</div>

Or you can just use foobar2000 to rename your files. It supports %\_\_bitspersample%

---

<div class="post-metadata">

### Author: ![lonelon2000](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/l/e99b99/32.png) [@lonelon2000](https://community.mp3tag.de/u/lonelon2000)
#### Post date: [July 14, 2013, 6:17am UTC](https://community.mp3tag.de/t/bits-per-sample-sample-size-16-bit-24-bit-tag/14831/8 "2013-07-14T06:17:17Z")

</div>

Thanks Dano, but I'd much rather do everything I can in one program. I've done so much scripting and formatting with MP3Tag, from getting album art, re-encoding files with dbPowerAmp, it only makes sense to build upon every customization I've built...

So now I can rename files with bits per sample in the filename with dbPowerAmp... Yes.. I've done it! 🙂 ![:w00t:](https://community.mp3tag.de/uploads/default/original/1X/cb01eca72fe9339ff6f3ec9f1e3c5fe002be0f0a.gif ":w00t:") ![:music:](https://community.mp3tag.de/uploads/default/original/1X/2ba05d1ade5eb0d15fc173be6f717dbe63890a70.gif ":music:") 😃

So in the end, I was able to compile an executable from the PowerShell script I wrote... (thanks to the kind folks at Quest for including the feature in PowerGUI, which is a free download...) and now it works as a "standalone" (you must have PowerShell installed) executable that accepts the full path to the audio file as a parameter!

Now I'll be creating multiple executables and configure them as a separate tool in MP3Tag for every different format I need.. there aren't that many, maybe 5 or 6 tops. Problem solved!!

---

<div class="post-metadata">

### Author: ![cedricpah](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/c/958977/32.png) [@cedricpah](https://community.mp3tag.de/u/cedricpah)
#### Post date: [April 15, 2020, 8:28am UTC](https://community.mp3tag.de/t/bits-per-sample-sample-size-16-bit-24-bit-tag/14831/9 "2020-04-15T08:28:41Z")

</div>

Hi, I found this post as the first response with google. So i want to help future users, yes, you can add column with value %\_bitspersample% and it works with flac files. Not for mp3.

---

<div class="post-metadata">

### Author: ![LyricsLover](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/l/c6cbf5/32.png) [@LyricsLover](https://community.mp3tag.de/u/LyricsLover)
#### Post date: [January 31, 2021, 11:36pm UTC](https://community.mp3tag.de/t/bits-per-sample-sample-size-16-bit-24-bit-tag/14831/10 "2021-01-31T23:36:51Z")

</div>

@cedricpah You are right now, because the developer introduced `%_bitspersample%` in November 2015:

> [@Bits per sample](https://community.mp3tag.de/t/bits-per-sample/14306/6):
>
> From the [Changelog](https://www.mp3tag.de/en/changelog.html): [2015-11-08] NEW: added information field %\_bitspersample% for some supported file types.

---

<div class="post-metadata">

### Author: ![Dypsis](https://community.mp3tag.de/user_avatar/community.mp3tag.de/dypsis/32/7878_2.png) [@Dypsis](https://community.mp3tag.de/u/Dypsis)
#### Post date: [June 21, 2021, 11:05pm UTC](https://community.mp3tag.de/t/bits-per-sample-sample-size-16-bit-24-bit-tag/14831/11 "2021-06-21T23:05:08Z")

</div>

That's what I need. A Sample Size column.

Thanks all.

---

<div class="post-metadata">

### Author: ![ohrenkino](https://community.mp3tag.de/user_avatar/community.mp3tag.de/ohrenkino/32/4843_2.png) [@ohrenkino](https://community.mp3tag.de/u/ohrenkino)
#### Post date: [June 22, 2021, 4:51am UTC](https://community.mp3tag.de/t/bits-per-sample-sample-size-16-bit-24-bit-tag/14831/12 "2021-06-22T04:51:50Z")

</div>

See the [help on how to handle columns](https://docs.mp3tag.de/customization/file-list).
