Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
clementine cannot play songs with foreign names[solved]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Multimedia
View previous topic :: View next topic  
Author Message
Adel Ahmed
Veteran
Veteran


Joined: 21 Sep 2012
Posts: 1523

PostPosted: Mon Aug 25, 2014 7:59 am    Post subject: clementine cannot play songs with foreign names[solved] Reply with quote

clementine skips songs that have foreign characters in their name (for example: Slaget vid Blodsälv.mp3)
eselect locale list | grep en_US
[237] en_US
[238] en_US.iso88591
[239] en_US.utf8 *
adel@localhost /media/hdd/songs/metal/Finntroll/2001 - Finntroll - Jaktens Tid $


$locale
LANG=en_US.utf8
LC_CTYPE="en_US.utf8"
LC_NUMERIC="en_US.utf8"
LC_TIME="en_US.utf8"
LC_COLLATE="en_US.utf8"
LC_MONETARY="en_US.utf8"
LC_MESSAGES="en_US.utf8"
LC_PAPER="en_US.utf8"
LC_NAME="en_US.utf8"
LC_ADDRESS="en_US.utf8"
LC_TELEPHONE="en_US.utf8"
LC_MEASUREMENT="en_US.utf8"
LC_IDENTIFICATION="en_US.utf8"
LC_ALL=


thanks


Last edited by Adel Ahmed on Sat Aug 30, 2014 5:57 am; edited 1 time in total
Back to top
View user's profile Send private message
Adel Ahmed
Veteran
Veteran


Joined: 21 Sep 2012
Posts: 1523

PostPosted: Tue Aug 26, 2014 12:15 pm    Post subject: Reply with quote

help anyone?
Back to top
View user's profile Send private message
VoidMage
Watchman
Watchman


Joined: 14 Oct 2006
Posts: 6196

PostPosted: Wed Aug 27, 2014 1:53 am    Post subject: Reply with quote

Well, let's try to establish a few facts.
1. due to the quirks of filesystem encoding, are you sure the filename didn't get messed up ?
2. clementine is based on gstreamer 0.10 (probably a qt4 limitation), so does 'gst-launch-0.10 playbin2 uri=<foo>' plays the file correctly ?
Back to top
View user's profile Send private message
Adel Ahmed
Veteran
Veteran


Joined: 21 Sep 2012
Posts: 1523

PostPosted: Wed Aug 27, 2014 6:19 am    Post subject: Reply with quote

here's what I got when I tried using gst-launch:
$ gst-launch-0.10 playbin2 uri=/media/hdd/songs/metal/Finntroll/2001\ -\ Finntroll\ -\ Jaktens\ Tid/Slaget\ vid\ Blodsälv.mp3
Setting pipeline to PAUSED ...
ERROR: Pipeline doesn't want to pause.
ERROR: from element /GstURIDecodeBin:uridecodebin0: Invalid URI "/media/hdd/songs/metal/Finntroll/2001 - Finntroll - Jaktens Tid/Slaget vid Blods?lv.mp3".
Additional debug info:
/var/tmp/portage/media-libs/gst-plugins-base-0.10.36-r1/work/gst-plugins-base-0.10.36/gst/playback/gsturidecodebin.c(1262): gen_source_element (): /GstPlayBin2:playbin20/GstURIDecodeBin:uridecodebin0
Setting pipeline to NULL ...
Freeing pipeline ...
Back to top
View user's profile Send private message
i92guboj
Bodhisattva
Bodhisattva


Joined: 30 Nov 2004
Posts: 10315
Location: Córdoba (Spain)

PostPosted: Wed Aug 27, 2014 6:35 am    Post subject: Reply with quote

blakdeath wrote:
here's what I got when I tried using gst-launch:
$ gst-launch-0.10 playbin2 uri=/media/hdd/songs/metal/Finntroll/2001\ -\ Finntroll\ -\ Jaktens\ Tid/Slaget\ vid\ Blodsälv.mp3
Setting pipeline to PAUSED ...
ERROR: Pipeline doesn't want to pause.
ERROR: from element /GstURIDecodeBin:uridecodebin0: Invalid URI "/media/hdd/songs/metal/Finntroll/2001 - Finntroll - Jaktens Tid/Slaget vid Blods?lv.mp3".
Additional debug info:
/var/tmp/portage/media-libs/gst-plugins-base-0.10.36-r1/work/gst-plugins-base-0.10.36/gst/playback/gsturidecodebin.c(1262): gen_source_element (): /GstPlayBin2:playbin20/GstURIDecodeBin:uridecodebin0
Setting pipeline to NULL ...
Freeing pipeline ...


The way gst-launch outputs the file name gives us a hint.

So, this can either be a bug in gst-launch or it could be that your filesystem is not capable or correctly mounted to handle utf8 encoding (which you will need if you want to be able to store file names with any arbitrary character from almost any alphabet in the world.

It could also be a utf-8-less terminal just screwing the output, though.

Most standard linux fs's will obey the settings in your kernel. Concretely, under filesystems->native language. There you must check the desired encodings, the set the default one to "utf8" if you want to be able to use any imaginable file name. If you don't want to set that the default at kernel level for some reason, you can still use the iocharset mount option when mounting a given fs to set the file name encoding to utf8.

I am assuming that you did at least the basic unicode setup, and that your system is localized to use unicode (use flags, glibc locales, etc). If not, you should start here:

https://wiki.gentoo.org/wiki/UTF-8
Back to top
View user's profile Send private message
krinn
Watchman
Watchman


Joined: 02 May 2003
Posts: 7470

PostPosted: Wed Aug 27, 2014 12:07 pm    Post subject: Reply with quote

https://forums.gentoo.org/viewtopic-t-995464.html

Like i said here: mistake utf8 and UTF-8 one works, the other not.
Back to top
View user's profile Send private message
Adel Ahmed
Veteran
Veteran


Joined: 21 Sep 2012
Posts: 1523

PostPosted: Wed Aug 27, 2014 12:45 pm    Post subject: Reply with quote

I've enabled the unicode and nls flags globally and reemerged everything that needed reemerging, I've also followed the guide and set the locale from utf8 to UTF-8
nothing, I'm getting the same error
what I've noticed though:
ERROR: from element /GstURIDecodeBin:uridecodebin0: Invalid URI "/media/hdd/songs/metal/Finntroll/2001 - Finntroll - Jaktens Tid/Slaget vid Blodsälv.mp3".
the ä is not replaced with ?(this happened when I enabled unicode and nls)
Back to top
View user's profile Send private message
VoidMage
Watchman
Watchman


Joined: 14 Oct 2006
Posts: 6196

PostPosted: Thu Aug 28, 2014 8:03 pm    Post subject: Reply with quote

One minor thing: it's 'uri' not 'filename' - it should start with 'file://'.
Back to top
View user's profile Send private message
Adel Ahmed
Veteran
Veteran


Joined: 21 Sep 2012
Posts: 1523

PostPosted: Fri Aug 29, 2014 4:32 am    Post subject: Reply with quote

like this?
gst-launch-0.10 playbin2 file:///media/hdd/songs/metal/Finntroll/2001\ -\ Finntroll\ -\ Jaktens\ Tid/Slaget\ vid\ Blodsälv.mp3
Setting pipeline to PAUSED ...
ERROR: Pipeline doesn't want to pause.
ERROR: from element /GstPlayBin2:playbin20: No URI set
Additional debug info:
/var/tmp/portage/media-libs/gst-plugins-base-0.10.36-r1/work/gst-plugins-base-0.10.36/gst/playback/gstplaybin2.c(3824): setup_next_source (): /GstPlayBin2:playbin20
Setting pipeline to NULL ...
Freeing pipeline ...
Back to top
View user's profile Send private message
VoidMage
Watchman
Watchman


Joined: 14 Oct 2006
Posts: 6196

PostPosted: Fri Aug 29, 2014 9:17 am    Post subject: Reply with quote

:roll: 'uri=file://<foo>'...
Back to top
View user's profile Send private message
Adel Ahmed
Veteran
Veteran


Joined: 21 Sep 2012
Posts: 1523

PostPosted: Fri Aug 29, 2014 12:43 pm    Post subject: Reply with quote

oops :D
ok I tried uri=file://
and it's working
clementine is still incapable of playing that same file though
Back to top
View user's profile Send private message
VoidMage
Watchman
Watchman


Joined: 14 Oct 2006
Posts: 6196

PostPosted: Fri Aug 29, 2014 2:42 pm    Post subject: Reply with quote

OK, next step: 'locale, LC_ALL=C ls -b <that file>'.
Also, run clementine from the same terminal, to establish that locale settings in the environment clementine is run in match the ones in the terminal (as they don't need to).
Back to top
View user's profile Send private message
Adel Ahmed
Veteran
Veteran


Joined: 21 Sep 2012
Posts: 1523

PostPosted: Sat Aug 30, 2014 5:57 am    Post subject: Reply with quote

well, LC_ALL=C just rendered my terminal incapable of displaying the foreign characters, I can play the song though using the terminal
so what I did was erase my old playlist and create the exact same one(scanning a folder) the names are displaying correctly now and I can finally listen to my music
not sure what fixed this

it could've been the global nls flag, the glocal unicode flag recompiled a couple of packages so it might be the solution as well(I don't think it's likely though)
generating the UTF-8 locale might have also been the solution

later on I'll try disabling the nls flag again and see if that was the problem

thanks everyone
Back to top
View user's profile Send private message
VoidMage
Watchman
Watchman


Joined: 14 Oct 2006
Posts: 6196

PostPosted: Sun Aug 31, 2014 7:21 pm    Post subject: Reply with quote

:sigh: the point of ' LC_ALL=C ls -b <that file>' was exactly just to print that name with C escapes for anything outside ASCII, to establish if the name is actually utf8.
Back to top
View user's profile Send private message
Adel Ahmed
Veteran
Veteran


Joined: 21 Sep 2012
Posts: 1523

PostPosted: Mon Sep 01, 2014 10:41 am    Post subject: Reply with quote

ah ok I see
I've removed the nls nad unicode flags and everything is still working, it's definitely the UTF-8

thanks everyone
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Multimedia All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum