Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Internet radio recording #7

Open
artenax opened this issue Oct 6, 2024 · 3 comments
Open

Internet radio recording #7

artenax opened this issue Oct 6, 2024 · 3 comments

Comments

@artenax
Copy link

artenax commented Oct 6, 2024

Hi. I use this player to listen and record online radio. In the settings I enabled radio recording, split into tracks (by the way, this checkbox doesn't work, the split is always performed, but I'm fine with it because it's convenient). Problems:

  1. Using Ogg Vorbis and FLAC formats leads to unreadable files after splitting (i.e. when switching tracks in the stream). Since these formats are not functional if you cut off their heads. And the player does exactly that, first encodes, then cuts by tags.
    I'm experimenting on this stream http://nashe1.hostingradio.ru/rock-128.mp3

  2. Using MP3 is devoid of this problem. However, I've noticed that the quality setting has no effect on the bitrate. It is always default for Lame encoder, I think V2 VBR (~120...150 kbps). I have done some debugging.

git clone --depth=1 https://github.com/thothix/guayadeque
cd guayadeque
mkdir build-dir && cd build-dir
cmake .. -G Ninja -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=/opt/guayadeque -DENABLE_IPOD=OFF -DwxWidgets_USE_DEBUG=ON
ninja
sudo ninja install
GST_DEBUG=*:4 gdb /opt/guayadeque/bin/guayadeque
run
search: quality

0:00:10.546186048 520939 0x555556f7ca40 INFO lamemp3enc gstlamemp3enc.c:921:gst_lamemp3enc_setup: lame encoder setup (target quality, quality 4,000000, bitrate 320, 44100 Hz, 2 channels)

gstreamer lame encoder always uses target quality, quality 4.0, then the bitrate is specified, but it is ignored because quality mode is used. Default lame quality is 4, which is pretty bad. I rebuilt gstreamer1.0-plugins-good (libgstlame.so) and set the default quality to 0 (ext/lame/gstlamemp3enc.c #define DEFAULT_QUALITY 0). But it's not easy and it's a hack. It's not mp3 320k, but it's close - VBR 0 (~220 kbps).

  1. Cut mp3 files have inaccurate navigation in players.

It's the most useful internet radio app under Linux though, thanks.
Upd: I am using Xubuntu 22.04.

@artenax
Copy link
Author

artenax commented Oct 7, 2024

Is it possible to record radio stations without transcoding or is it not possible in gstreamer?

@thothix
Copy link
Owner

thothix commented Oct 10, 2024

I need to take a look to this recording feature.

@artenax
Copy link
Author

artenax commented Nov 13, 2024

VLC can also record internet radio, without transcoding, with cutting files by tags.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants