Page 1 of 1
VLC Android Auto - Tracks list shows spinner only
Posted: 31 Dec 2020 19:02
by testerman
Greetings,
VLC for Android is a godsend since the selection of music players for Android Auto is dominated by the Big Data guys who all want to sell you something. I will be contributing to this project.
My issue is with selecting the Track List. Doing this on the phone directly brings up the list as it should, but on the cars display I get a spinner and it seems to stay there longer than my patience will allow. Last time it was about 30 minutes.
I have a large collection of music >30Gig. Again, the phone has already sorted the list and it does displays properly on the device when not connected to Android Auto.
Re: VLC Android Auto - Tracks list shows spinner only
Posted: 01 Jan 2021 20:35
by rstone
I am glad you are enjoying the Android Auto interface. I contributed the updates earlier this year to the UI, so I am familiar with the issue you are experiencing.
First, just to verify--you are using the latest version, 3.3.2, correct? I want to make sure my comments are reflective of the current state of the UI, rather than an older release. Can you tell me what version of Android you are running, phone model, etc. ?
Second, the issue you are observing is a result of the design of the Android Auto API, which only allows us to send back a large data structure containing all the songs for the track list. It isn't elegantly designed for pagination, unfortunately. The way the list is passed data is serialized internally into a Parcel, which is limited in size to approximately 1 MB. With the tracks in my playlist, I empirically determined this to be approximately 930-ish songs, but I padded it down to exactly 800 to leave some room. We iterate over the track list until we hit 800--wherever that might be alphabetically, and then stop. This is the reason you see the track list "Search by letter" frequently truncates the end of the alphabet. Sadly, there's nothing we can do about the API design unless we create the pagination ourselves, such as A->(whatever letter lands at track 800), followed by 801->1600, 1601->2400, you get the idea. We'd have to insert another menu level below Tracks to enable that functionality, which I suppose is doable. Is that something you would find valuable?
Third, there is a subtle data sizing issue with determining the number of bytes used by each track in the data structure. In order to load the artwork, we pass the file path internally to the ContentProvider responsible for returning the image to Android Auto. This will be impacted by the depth of the directory structure, folder name length, etc. I am currently working on a new ArtworkProvider which will make the size much more predictable by only passing the internal media id number and not the entire path. We'll be able to more predictably hit the 800 track number that way without worrying about the on-disk organization of the media library. This also resolves the bug with incorrect cover art appearing after the Android Auto cache fills up. I assume you are still seeing that issue, but perhaps you have learned to ignore it?
If you are able to view the logs, I think you'll see a TransactionTooLargeException, followed by a message that says "!!! FAILED BINDER TRANSACTION !!!". Can you post the message, including the allowed parcel size? It's going to happen almost immediately after navigation.
Thanks!
Re: VLC Android Auto - Tracks list shows spinner only
Posted: 02 Jan 2021 08:56
by testerman
RStone
Hello and Happy New Year. Good Riddance to 2020.
I am running on Version 3.3.2. While my device is older, is is still very good. So, okay I am on a rooted (Magisk) OnePlus 1. That's right this thing is on Marshmallow and is nearly 8 years old. Best phone I ever had. Better than my new Note10. The reason I use the older device it is that it is connected to the car 24/7. I do not want to root my main ride so to speak.
As to a re-write for my benefit I don't think I'd want anyone to dedicate their time to solve a one-off problem that I am having. Although I do appreciate the consideration.
I am new to VLC Android and I was curious to the use of an icon that to me when I saw it it said "CrossFade" but it looks like it is being used as a shuffle icon. The thing is the icon shows one stream reducing while one is ramping up. I was very confused about this. Have I misinterpreted something?
I am currently cleaning the folder structure of my 30G collection in hope that being simplified would help.
I see there is a setting to start logging so I will give that a go next time I get to use it.
One other peculiarity is that it is that VLC starts and stays in Landscape mode even though it is disconnected from the car. This is the only app I have seen do this.
Thanks for your help
D
Re: VLC Android Auto - Tracks list shows spinner only
Posted: 03 Jan 2021 06:52
by testerman
RStone,
Here is a clip from the log file. I could not find the TransactionTooLargeException but the Failed Binder string is shown below.
I hope this helps.
D.
01-02 12:15:23.025 W/ViewRootImpl(13552): Dropping event due to no window focus: MotionEvent { action=ACTION_MOVE, actionButton=0, id[0]=0, x[0]=0.0, y[0]=1274.3539, toolType[0]=TOOL_TYPE_FINGER, buttonState=0, metaState=0, flags=0x0, edgeFlags=0x0, pointerCount=1, historySize=1, eventTime=52792291, downTime=52792072, deviceId=5, source=0x1002 }
--------- beginning of main
01-02 12:16:29.410 E/JavaBinder(13552): !!! FAILED BINDER TRANSACTION !!! (parcel size = 756372)
01-02 12:16:29.410 W/MBServiceCompat(13552): Calling onLoadChildren() failed for id=ID_TRACKS package=com.google.android.projection.gearhead
01-02 12:20:08.876 W/VLC/VLCApplication(13552): onTrimMemory, level: 20
01-02 12:20:09.322 D/VLC (13552): [9383b030/34f0] libvlc generic: creating audio output
01-02 12:20:09.322 D/VLC (13552): [939507b0/34f0] libvlc audio output: looking for audio output module matching "android_audiotrack": 4 candidates
01-02 12:20:09.323 D/VLC (13552): [939507b0/34f0] libvlc audio output: using audio output module "android_audiotrack"
01-02 12:20:09.323 D/VLC (13552): [9383b030/34f0] libvlc generic: keeping audio output
01-02 12:20:09.324 D/VLC (13552): [939504b0/5c76] libvlc audio output: removing module "android_audiotrack"
01-02 12:20:09.549 D/VLC (13552): [939507b0/5c76] libvlc audio output: removing module "android_audiotrack"
01-02 12:24:28.679 D/OpenGLRenderer(13552): endAllStagingAnimators on 0x96cf2700 (RippleDrawable) with handle 0x938f6c30
01-02 12:25:28.365 W/IInputConnectionWrapper(13552): getExtractedText on inactive InputConnection
01-02 12:25:28.365 W/IInputConnectionWrapper(13552): getTextBeforeCursor on inactive InputConnection
01-02 12:25:29.257 W/IInputConnectionWrapper(13552): getExtractedText on inactive InputConnection
01-02 12:25:29.267 W/IInputConnectionWrapper(13552): getTextBeforeCursor on inactive InputConnection
01-02 12:28:47.785 W/IInputConnectionWrapper(13552): getTextAfterCursor on inactive InputConnection
01-02 12:28:47.791 W/VLC/VLCApplication(13552): onTrimMemory, level: 20
01-02 12:28:47.795 W/IInputConnectionWrapper(13552): beginBatchEdit on inactive InputConnection
01-02 12:28:47.795 W/IInputConnectionWrapper(13552): endBatchEdit on inactive InputConnection
01-02 12:28:47.806 W/IInputConnectionWrapper(13552): getTextBeforeCursor on inactive InputConnection
01-02 12:28:47.817 W/IInputConnectionWrapper(13552): getExtractedText on inactive InputConnection
01-02 12:28:47.817 W/IInputConnectionWrapper(13552): getTextBeforeCursor on inactive InputConnection
01-02 12:28:47.987 D/VLC (13552): [93996550/34f0] libvlc generic: creating audio output
01-02 12:28:47.987 D/VLC (13552): [93950f30/34f0] libvlc audio output: looking for audio output module matching "android_audiotrack": 4 candidates
01-02 12:28:47.987 D/VLC (13552): [93950f30/34f0] libvlc audio output: using audio output module "android_audiotrack"
01-02 12:28:47.988 D/VLC (13552): [93996550/34f0] libvlc generic: keeping audio output
Re: VLC Android Auto - Tracks list shows spinner only
Posted: 09 Jul 2021 21:31
by rstone
Hi Testerman,
Could you install a copy of VLC 3.4.0 Beta 2 from
https://artifacts.videolan.org/vlc-android/release/ and give this another try? (use arm64-v8a first. If that doesn't install, then try armeabi-v7a). I merged a number of changes over the past six months which should correct the issue you encountered.
I resolved the spinner issue via a couple of modifications, including:
1. The URL passed for the artwork is shorter and more consistent. It no longer points directly to a path on disk. It uses a content provider to load the imagery behind the scenes.
2. The path to the actual track is no longer passed in the navigation menu. It wasn't used, and consumed a significant number of bytes, especially for deep folder structures.
3. An intermediary menu is now added between "Tracks" and the listing of actual songs which paginates the library into alphabetically sorted drill-downs. This is fully-compatible with navigation using the Android Auto pop-up keyboard.
Please test it out and let me know how it works for you.
Thanks!