Bug 322370 - Ripping ogg track from audiocd fails
Summary: Ripping ogg track from audiocd fails
Status: RESOLVED FIXED
Alias: None
Product: kio
Classification: Frameworks and Libraries
Component: audiocd (show other bugs)
Version: 4.10.5
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: icefox
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-07-14 22:25 UTC by tim
Modified: 2013-09-18 14:44 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In: 4.11.2


Attachments
ogg (23.23 KB, audio/ogg)
2013-07-14 22:26 UTC, tim
Details
Rip out legacy libvorbis support (<2002) which is broken in the first place and prevents kio-audiocd from encoding vorbis files at the moment (483 bytes, patch)
2013-09-01 22:52 UTC, artjom.simon
Details

Note You need to log in before you can comment on or make changes to this bug.
Description tim 2013-07-14 22:25:53 UTC
conbert a track from audiocd to ogg with dolphin or amarok fails.  

-the process is very slow
-the ogg-file is small (~25kb)
-i can't play the file with various players (vlc...)
-convert to mp3 and flac works
-k3b works

manually ripping with cdparanoia and oggenc works. 

Reproducible: Always

Steps to Reproduce:
1.try to convert a file from audiocd with doplhin, konqueror, amarok to ogg
2.play the ogg-file
3.nothing / crash (amarok)
Actual Results:  
small ogg-file, not playable

Expected Results:  
playable ogg-musicfile
Comment 1 tim 2013-07-14 22:26:43 UTC
Created attachment 81113 [details]
ogg
Comment 2 artjom.simon 2013-09-01 21:49:18 UTC
kio_audiocd basically can't rip vorbis files at the moment (KDE 4.11)

This is also reproduced in Bug 322944 https://bugs.kde.org/show_bug.cgi?id=322944

To reproduce, try to rip any audio CD into an ogg file, and run "ogginfo file.ogg":

> ogginfo test.ogg 
> Processing file "test.ogg"...

> New logical stream (#1, serial: 77ae2052): type vorbis
> Vorbis headers parsed for stream 1, information follows...
> Version: 0
> Vendor: Xiph.Org libVorbis I 20120203 (Omnipresent)
> Channels: 2
> Rate: 44100

> Nominal bitrate: 256,000000 kb/s
> Upper bitrate: 4294967,295000 kb/s
> Lower bitrate: 4294967,295000 kb/s
> User comments section follows...
 >        kde-encoder=kio_audiocd
> Negative or zero granulepos (0) on Vorbis stream outside of headers. This file was created by a buggy encoder
> Negative or zero granulepos (0) on Vorbis stream outside of headers. This file was created by a buggy encoder
...
Comment 3 artjom.simon 2013-09-01 22:52:22 UTC
Created attachment 82098 [details]
Rip out legacy libvorbis support (<2002) which is broken in the first place and prevents kio-audiocd from encoding vorbis files at the moment

This rips out #defines like these:

#if HAVE_VORBIS >= 2 // If really old Vorbis is being used, skip this nicely.

This is broken, because nowhere is HAVE_VORBIS set to higher than 1, which prevents reaching the newer code (which works) and always falls back to pre-2002 code, which worked with vorbis rc3, but doesn't today.

I presume it's safe to risk stopping supporting pre-2002 vorbis libraries in the next release.
Comment 4 artjom.simon 2013-09-01 22:55:42 UTC
See attached patch for a solution (since it's trivial and short (and my first KDE patch ever), please ignore that it probably doesn't comply to any patch submission guidelines.

While in ~/audiocd-kio/plugins/vorbis, just
> patch encodervorbis.cpp encodervorbis.cpp.322370.patch

Recompile, install, voilà - encoding to ogg works again.
Comment 5 Richard Lärkäng 2013-09-02 18:33:01 UTC
A very similar (but from the looks of it, slightly more complete) patch can be found at:
http://lists.kde.org/?l=kde-multimedia&m=134903246822765
Comment 6 Richard Lärkäng 2013-09-02 19:13:04 UTC
Git commit acc3a0ed24e518fc44c9770f56058b4bdba9393c by Richard Lärkäng.
Committed on 02/09/2013 at 19:02.
Pushed by larkang into branch 'master'.

Fix Ogg/Vorbis support because HAVE_VORBIS is no longer set to 2
(since as far as I can see, the change to cmake)
See http://lists.kde.org/?l=kde-multimedia&m=134903246822765

Based on patches by the following people
CCMAIL: info@pc-tiede.de
CCMAIL: artjom.simon@gmail.com
FIXED-IN: 4.11.1

M  +2    -2    plugins/CMakeLists.txt
M  +0    -2    plugins/vorbis/CMakeLists.txt
M  +0    -20   plugins/vorbis/encodervorbis.cpp
M  +0    -4    plugins/vorbis/encodervorbis.h

http://commits.kde.org/audiocd-kio/acc3a0ed24e518fc44c9770f56058b4bdba9393c
Comment 7 sbecom2012 2013-09-17 09:50:41 UTC
Hi,
I'm using KUBUNTU 13.04 with KDE 4.11.1 backports and the bug as described is still not fixed :
-the process is very slow
-the ogg-file is small (~25kb)
-i can't play the file with various players (vlc...)
-convert to mp3 and flac works
-k3b works

I tried to recompile a patched audiocd-kio and built a .deb package with "checkinstall" to easily be able to uninstall it afterwards if any problem. 
As I can't smoothly uninstall previous audiocd-kio packages because package Kubuntu-desktop is linked to it, I used dpkg -r --force-all. Then I installed "my" audiocd-kio built .deb with dpkg -i, but it doesn't seem to be working (audiocd:/ protocol doesn't work anymore in dolphin).

I'll use K3b for the moment but I feel upset...
Comment 8 sbecom2012 2013-09-17 09:52:12 UTC
Sorry, I'm quite newbie and I just noticed that the bug was supposed to be fixed in 4.11.2...
Comment 9 Richard Lärkäng 2013-09-18 14:44:16 UTC
Yes, the fix was submitted just before 4.11.1 was released, but not in time for it to be included (which I mistakenly wrote it should be in the comment), so it should appear in 4.11.2 instead.