[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #58081] Clipping of samples in octave audiowri
From: |
anonymous |
Subject: |
[Octave-bug-tracker] [bug #58081] Clipping of samples in octave audiowrite function differs from matlab |
Date: |
Mon, 30 Mar 2020 07:19:13 -0400 (EDT) |
User-agent: |
Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:74.0) Gecko/20100101 Firefox/74.0 |
URL:
<https://savannah.gnu.org/bugs/?58081>
Summary: Clipping of samples in octave audiowrite function
differs from matlab
Project: GNU Octave
Submitted by: None
Submitted on: Mon 30 Mar 2020 11:19:11 AM UTC
Category: Octave Function
Severity: 3 - Normal
Priority: 5 - Normal
Item Group: Matlab Compatibility
Status: None
Assigned to: None
Originator Name: T Herzke
Originator Email: address@hidden
Open/Closed: Open
Release: 5.2.0
Discussion Lock: Any
Operating System: GNU/Linux
_______________________________________________________
Details:
Audio .wav files can contain audio samples in floating point format, e.g. 32
bit single precision floating point.
When saving octave/matlab data to .wav files as floating point data, then
there is no need to clip audio samples exceeding the range -1..+1. Matlab does
not apply clipping in this case but octave does. Please fix behaviour in
octave. Steps to reproduce:
samples = [0.5;2;0.5];
audiowrite('/tmp/samples.wav',samples,44100,'BitsPerSample',32)
samples2 = audioread('/tmp/samples.wav')
Matlab prints the original values for samples2
0.5000
2.0000
0.5000
while the same code executed in octave shows that the input sample 2 was
clipped to 1:
0.50000
1.00000
0.50000
I have compared Matlab 2020a against Octave 5.2.0, both on Linux.
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?58081>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Octave-bug-tracker] [bug #58081] Clipping of samples in octave audiowrite function differs from matlab,
anonymous <=