Support

If you have a problem or need to report a bug please email : support@dsprobotics.com

There are 3 sections to this support area:

DOWNLOADS: access to product manuals, support files and drivers

HELP & INFORMATION: tutorials and example files for learning or finding pre-made modules for your projects

USER FORUMS: meet with other users and exchange ideas, you can also get help and assistance here

NEW REGISTRATIONS - please contact us if you wish to register on the forum

Users are reminded of the forum rules they sign up to which prohibits any activity that violates any laws including posting material covered by copyright

Intersample peaks

For general discussion related FlowStone

Intersample peaks

Postby Drnkhobo » Sat Jul 12, 2014 12:16 pm

Hey guys, does anyone know how to implement an intersample peak meter?

I've tried some searching and nothing comes up on actual design. So I was wondering if anyone here had experience on this? Is it possible with FS?

My thoughts would be to do some math magic (up sample, interpolate liberally) ??

Any help would be appreciated :D
Drnkhobo
 
Posts: 312
Joined: Sun Aug 19, 2012 7:13 pm
Location: ZA

Re: Intersample peaks

Postby Tronic » Sat Jul 12, 2014 1:16 pm

generic info from here http://www.soundonsound.com/sos/feb14/a ... ss-war.htm
<< To detect inter-sample peaks a True Peak meter employs a relatively high oversampling ratio which allows it to more fully reconstruct the continuous audio waveform. BS.1770 calls for a minimum oversampling ratio of 4x, which gives a maximum possible under-read error of slightly less than 0.7dB. For that reason, the EBU recommends setting the permitted maximum level (PML) to -1dBTP, thus guaranteeing that the signal can never cause an overload or clipping in any following digital processing equipment or converters. (The ATSC A/85 recommendation sets a slightly more conservative PML of -2dBTP.)
Not surprisingly, the higher the oversampling ratio, the smaller the possible inter-sample under-read. An 8x oversampling ratio gives a maximum error of slightly less than 0.2dB, and 16x oversampling is accurate to within 0.05dB. However, higher oversampling ratios involve a greater processing overhead, and in practical terms the benefit is negligible in most cases. So the BS.1770 recommendation is for a PML of -1dBTP based on the more manageable 4x ratio, which is a very pragmatic solution adopted by the vast majority of loudness meter plug-in manufacturers. >>
Tronic
 
Posts: 539
Joined: Wed Dec 21, 2011 12:59 pm

Re: Intersample peaks

Postby trogluddite » Sat Jul 12, 2014 1:35 pm

I've seen 4x upsampling followed by peak estimation (termite interpolation seems popular) recommended in a few places - to meet the same standards that Tronic mentions.

Both are definitely possible with FS.
There was an oversampling toolkit available over on the SynthMaker forum - that should load OK to FS if it's still available. And I recall that martinvicanec did some good work on peak estimation for his pitch detector projects over at the SM site too. Martin hangs about here still, so he might be able to point you at the right parts of the code to extract.
All schematics/modules I post are free for all to use - but a credit is always polite!
Don't stagnate, mutate to create!
User avatar
trogluddite
 
Posts: 1730
Joined: Fri Oct 22, 2010 12:46 am
Location: Yorkshire, UK

Re: Intersample peaks

Postby Tronic » Sat Jul 12, 2014 1:52 pm

Tronic
 
Posts: 539
Joined: Wed Dec 21, 2011 12:59 pm

Re: Intersample peaks

Postby Drnkhobo » Sat Jul 12, 2014 2:29 pm

:lol: OOOH thanks guys!

I thought it would be done with oversampling. I will check these links out now & get back, much appreciated
Drnkhobo
 
Posts: 312
Joined: Sun Aug 19, 2012 7:13 pm
Location: ZA

Re: Intersample peaks

Postby Drnkhobo » Sat Jul 12, 2014 3:13 pm

loudness (LK) is then calculated:

LK = −0.691+10log10 ∑Gi ⋅zi

where Gi are the weighting coefficients for each channel.


What does that ∑ mean?
Drnkhobo
 
Posts: 312
Joined: Sun Aug 19, 2012 7:13 pm
Location: ZA

Re: Intersample peaks

Postby tester » Sat Jul 12, 2014 4:13 pm

On my computer looks like sigma (sum all).
Need to take a break? I have something right for you.
Feel free to donate. Thank you for your contribution.
tester
 
Posts: 1786
Joined: Wed Jan 18, 2012 10:52 pm
Location: Poland, internet

Re: Intersample peaks

Postby martinvicanek » Sun Jul 13, 2014 12:06 pm

trogluddite wrote:There was an oversampling toolkit available over on the SynthMaker forum - that should load OK to FS if it's still available.
IIRC the oversampling kit uses IIR filters which are not linear phase. That may distort the peaks. Not sure how severe that would be but I'd recommend a linear phase FIR. Perhaps a 4-point Lagrange interpolator would suffice?
trogluddite wrote: And I recall that martinvicanec did some good work on peak estimation for his pitch detector projects over at the SM site too.
Hmm, you mean the spectral peak estimation. Yes, that could probably also be used in the time domain, why not? Basically you look at the maximum (or minimum) sample and its two neighbors. Should be pretty lightweight on CPU compared to oversampling.

Edit: first analysis shows that neither 4-point Lagrange upsampling nor the neighbor-based peak estimation are particularly accurate in this context.
User avatar
martinvicanek
 
Posts: 1328
Joined: Sat Jun 22, 2013 8:28 pm

Re: Intersample peaks

Postby tulamide » Sun Jul 13, 2014 4:10 pm

Since the experienced users are all gathered, may I ask a question?

I know what intersample peaks are. Are they in any way harming? Since there are no intersample-samples in the digital domain, wouldn't they just be non-existant when the sound is outputted to the analog domain? Or will there still be some kind of curve between two samples, maybe due to the analog hardware?
"There lies the dog buried" (German saying translated literally)
tulamide
 
Posts: 2714
Joined: Sat Jun 21, 2014 2:48 pm
Location: Germany

Re: Intersample peaks

Postby Tronic » Sun Jul 13, 2014 5:02 pm

tulamide wrote:Since the experienced users are all gathered, may I ask a question?

I know what inter-sample peaks are. Are they in any way harming? Since there are no intersample-samples in the digital domain, wouldn't they just be non-existant when the sound is outputted to the analog domain? Or will there still be some kind of curve between two samples, maybe due to the analog hardware?

The ISP meter, measure the level above allowed by your D/A converter, and with an approximation to reconstruct the waveform at the points that exceeded 0dBFS, and measuring them, so to give a pseudo-value for recalibrate your level of output.
Tronic
 
Posts: 539
Joined: Wed Dec 21, 2011 12:59 pm

Next

Return to General

Who is online

Users browsing this forum: No registered users and 48 guests