Commit Graph

3049 Commits

Author SHA1 Message Date
evpobr
f1db22760b Update CHANGELOG.md 2021-04-20 13:26:37 +05:00
yuan
ced91d7b97
flac: Fix improper buffer reusing (#732) 2021-04-20 13:16:32 +05:00
evpobr
34bd39b9b5 [mpeg] Restore MPG123_NO_FRANKENSTEIN 2021-04-12 11:32:28 +05:00
evpobr
9349a566e2 [cmake] Separate API and ABI versions 2021-04-04 21:49:51 +05:00
Arthur Taylor
e79f45dac7 ogg_opus: Fix tabs messing up printf alignment. 2021-04-03 13:56:09 -07:00
Arthur Taylor
fe51e9b093 programs: Add MPEG related handling, other misc Ogg handling fixes.
- Add MPEG major and minor formats to string printing routines.

- Don't warn when adding a broadcast chunk to a MPEG WAV.

- sndfile-convert: Infer that ".ogg" suffix means Ogg+Vorbis. This
  aligns with Xiph.org

- sndfile-info: Properly calculate the dB of Vorbis and Opus files. The
  handling of the allowable sample range of these files may need to be
  investigated in future.
2021-04-03 13:56:09 -07:00
evpobr
d820a2d257 [mpeg] Temporarily disable MPG123_NO_FRANKENSTEIN flag
Related to #499, microsoft/vcpkg#16910.
2021-03-31 13:00:15 +05:00
evpobr
cad58f39ca [mpeg] Fix MPG123_NO_FRANKENSTEIN mode 2021-03-28 13:33:19 +05:00
evpobr
7fde60ac68 cmake: Fix package properties 2021-03-27 12:31:29 +05:00
evpobr
0d79fbef8b Update README.md 2021-03-27 12:27:32 +05:00
evpobr
16251b2d11 mpeg: Fix Windows build
Windows MSBuild builds of mpg123 have wrong MPG123_API_VERSION.
2021-03-27 11:56:27 +05:00
evpobr
b7c22419b6 cmake: Improve mpg123 handling
mpg123 has official imported target name.
2021-03-27 11:53:51 +05:00
evpobr
89214bdf05 cmake: Fix undefined HAVE_MPEG 2021-03-26 12:32:45 +05:00
evpobr
72521cf4f7 doc: Add information about MPEG support 2021-03-26 12:10:48 +05:00
Arthur Taylor
f97fa5e6ba id3: Remember id3v2 Header Info. Do Call mpeg_decode() Twice. 2021-03-25 10:26:15 -07:00
Arthur Taylor
b00db8b15c Add mpeg_init() for initializing the codec without file assumptions.
Future proofing for MPEG in WAV support.
2021-03-25 10:26:15 -07:00
Arthur Taylor
f401000fd0 Skip format_check_test for asymmetric MPEG Layer I/II
libmpg123 supports decoding MPEG Layers I, II, and III, but we only have
encode support for Layer III. Skip checks for I and II as they don't
have write support.
2021-03-25 10:26:15 -07:00
Arthur Taylor
64ce116687 Fix command_test Subformat count 2021-03-25 10:26:15 -07:00
Arthur Taylor
30ba21d6c2 mpeg: Align decode log printing 2021-03-25 10:26:15 -07:00
Arthur Taylor
fe2ed77134 Add MPEG FORMAT to SF_COMMAND_*FORMAT, program common. 2021-03-25 10:26:15 -07:00
Arthur Taylor
163f725631 Rename mp3 -> mpeg (file sources and function names) 2021-03-25 10:26:15 -07:00
Arthur Taylor
dae19b9502 Rename SF_FORMAT_MP3 to SF_FORMAT_MPEG 2021-03-25 10:26:15 -07:00
Arthur Taylor
d2c836d732 Workaround vcpkg yasm issues.
See https://github.com/microsoft/vcpkg/pull/14003
2021-03-25 10:26:15 -07:00
Arthur Taylor
663a59aa6e mpeg: Add MPEG Encode, Decode and Tests
Use SF_FORMAT_MP3 major and SF_FORMAT_MPEG_LAYER_(I|II|III) subformats.
2021-03-25 10:26:15 -07:00
evpobr
be637260f7 xi: Remove extra blank lines 2021-03-24 08:17:54 +05:00
evpobr
bde4a1364e sfendian: Use C99 variable declarations 2021-03-22 12:39:52 +05:00
evpobr
4539826643 Update CHANGELOG.md 2021-03-19 11:33:49 +05:00
evpobr
1875f49bbf common: Allow to use C99 bool 2021-03-18 15:10:35 +05:00
evpobr
e85da03c6a common: Remove NOT macro 2021-03-18 14:36:35 +05:00
evpobr
d617fafe50 dwd: Use fixed width integer types 2021-03-18 13:55:50 +05:00
evpobr
b1d642078f sndfile: Improve SF_INFO correctness check
Limit maximum `samplerate` and `channels` values.

Update API documentation to reflect changes.

This should also fix some possible integer overflows as:

https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=28441

Credit to OSS-Fuzz.
2021-03-18 10:29:25 +05:00
evpobr
40fdc3121b common: Fix initialized va_list leaks
Thanks to clang-tidy.
2021-03-17 10:58:10 +05:00
evpobr
c0c81a5bde sndfile-to-text: Return proper error code 2021-03-16 18:56:26 +05:00
evpobr
8ff8ed6967 sndfile-to-text: Fix large stack allocation 2021-03-16 16:54:17 +05:00
evpobr
6fb0313563 sndfile-interleave: Fix large stack allocation 2021-03-16 16:30:07 +05:00
evpobr
19a4498736 sndfile-deinterleave: Fix resource cleanup 2021-03-16 16:30:07 +05:00
evpobr
9dee1e060b aiff: Fix typos 2021-03-15 16:02:16 +05:00
evpobr
dadf54b91e ci: Fix test failure 2021-03-14 22:08:01 +05:00
evpobr
e8293c29da pcm: Wrap CPU endian specific code in #ifdefs 2021-03-14 19:24:25 +05:00
brianlheim
61b5343584 sndfile.hh: add portability documentation 2021-03-07 22:37:23 +05:00
brianlheim
1c48ce31f6 sndfile.hh: use nullptr when available 2021-03-07 22:37:23 +05:00
brianlheim
b46de402d5 Revert "Fix zero-as-null-pointer-constant-warning"
This reverts commit 2269af8417.

The code which defined nullptr mysteriously broke the Windows build for
SuperCollider. After some investigation I discovered this commit to be the
cause, as MSVC by default does not set __cplusplus to anything greater
than 199711L unless explicitly asked to.

In general, #defining a keyword like nullptr in a library header is not
courteous, as it can affect compilation of later code and cause
significant confusion. This was exactly the situation I encountered, and
it took several days to track down the source.

The stated reason for the commit reverted by this was to prevent a
specific warning from appearing during compilation. However, there are
a few less intrusive ways of accomplishing this. For example, by using
`#pragma`s offered by all major compilers which temporarily disable
warnings, or by including headers with `-isystem` or any similar
mechanism which disables warnings from "system" headers. For code which
is intended to support C++98 and newer standards, preventing all
compilers from emitting any warnings is a losing battle. It is easier
in my view for consuming code to handle this as it needs to.

There are several options here for resolving this. I could just fix my
project, but that would not prevent others from encountering the same
issue. I could try for a clever-er version of this using a macro not
named nullptr and an additional check for MSVC, but this seems to offer
diminishing returns considering how easily any warnings about NULL can
be silenced, and carries the risk of introducing new and unforeseen
problems. So, I have here simply reverted the commit so the code uses
NULL once again.
2021-03-07 22:37:23 +05:00
evpobr
9b398f0101 Merge branch 'master' of https://github.com/libsndfile/libsndfile 2021-03-07 11:37:23 +05:00
evpobr
5645fa8ee8 ci: Speed up Autotools tests
We run them twice.
2021-03-07 11:37:19 +05:00
evpobr
97f9e64b39 sfendian: Fix byteswap optimizations detection 2021-03-07 11:35:42 +05:00
evpobr
6dee7120ab sndfile-salvage: Handle files > 4 GB on Windows OS 2021-03-06 21:44:33 +05:00
evpobr
36c5198d91 common: Fix regression after 4ff3b84 2021-03-06 12:00:31 +05:00
evpobr
61bcb5e979 Fix previous commit 2021-03-06 11:54:08 +05:00
evpobr
4ff3b84eff msvc: Fix annoying conversion warnings #304 2021-03-06 11:41:47 +05:00
evpobr
1578687eb3 common: Move psf_isprint() to source file 2021-03-05 12:02:01 +05:00