Fansite and Forum for Meizu Products
 
       

Go Back   Meizu Me > Meizu Product Discussions > miniPlayer M6 / SL > Firmware > Modifications and Skins

Reply
 
Thread Tools
Old 03-30-2008   #1
Member
 
Join Date: Oct 2007
Location: Finland
Posts: 137
[SCRIPT] fancy album art script

Check bottom of this post for Windows (DOS) version. (updated to v0.3)

Here's the bash script, that some of you Linux users out there might want, which will create fancy album art.

I created it to go with my BRITE skin, but it'll work with any skin, of course.

You need ImageMagick for this and a little bit of script knowledge to set the 3 or 4 paths, but that shouldn't be too difficult for most Linux users. The script will query your amarok music and find the appropriate album art, resize it, optionally add some magic to make it extra pretty and load it to your music directory.

Requirements:
  • ImageMagick
  • mounted miniplayer
  • already know that album art is working with your directory setup
Preparations:
  • set the path of the miniplayer music directory in the MUSICDIR variable
  • set the path of your amarok albumcovers/large (script has a default location)
  • set the path of the nocover.png image (also downloadble here
  • optionally, set the path to the temp directory you want the script to use
  • for ease of use, make sure the file is executable and in your $PATH environment variable
  • the script assumes your MUSIC directory contains a structure like this: "<artistname>-<albumname>" and it will place an <albumname>.jpg file in those directories. Of course if you use another way of displaying album art, you can adjust this in the script
How to use:

Code:
$ meizu_amarok_albumart
This will just place regular album art on your miniplayer, like we're used to

Code:
$ meizu_amarok_albumart true
This will put a fancy version, with reflection, on a black background, so only suitable for a black background, on your miniplayer

Code:
$ meizu_amarok_albumart true <absolute_path_to_your_wallpaper>
This will put a fancy version of your album art, with reflection based on the supplied background. This can be a background that's on your miniplayer in the PICTURES directory or any other place.The result of the most fancy version you can see in the attached screenshot.

Any suggestions are welcome, of course. If I feel like it, maybe I'll make one based on (Py)Qt for easier configuration, though once you have the configuration set, there's not much else you'd need a gui for.

--------------------------------------------------------------------------------

Windows/DOS version
Couldn't stand it, had to do one for 'the rest' of the world. So, below is a Windows download. You must alsow have ImageMagick installed.

Now, for the script instructions. Just extract the zip to a location of your choice. First edit the meizu_albumart.bat file to set your MUSIC directory (the one on your miniplayer). Make sure the miniplayer is connected so that you enter the correct path. Then, go to a DOS prompt, cd to the location of the batch file and run it:

Code:
meizu_albumart.bat <optional_path_to_background_image>
That's all there is to it. How it works? The first script is sort of a wrapper which searches through your miniplayer's MUSIC directory, checking for jpg files. If it finds one, it calls the other script and converts it to look all pretty. So, don't forget: you need to have your albumart in place already.

Known bugs
- DOS' SET command can't calculate with decimals, so the alignment of the albumart with the reflection might not be perfect. There are calculation tools that can do this, might build support for that later or find another way.

Changelog

version 0.3
------------------------------
20080426 - Changed: added comments so it's easier for others to use

version 0.2
------------------------------
20080403 - Fixed: slashes don't always work in paths, converted to backslashes
Attached Images
File Type: jpg screen-music.jpg (72.8 KB, 505 views)
Attached Files
File Type: zip meizu_amarok_albumart.zip (13.0 KB, 89 views)
File Type: zip meizu_albumart_windows-0.3.zip (1.8 KB, 101 views)
__________________

Last edited by parena; 04-26-2008 at 07:22 AM. Reason: windows version updated to 0.3
parena nincs online   Reply With Quote
Old 04-01-2008   #2
Passing By
 
shem's Avatar
 
Join Date: Mar 2008
Posts: 5
Waiting for the Windows script
Look so good!!
What about resized album art,any ideas??
shem nincs online   Reply With Quote
Old 04-01-2008   #3
Member
 
Join Date: Oct 2007
Location: Finland
Posts: 137
Don't hold your breath for the Windows script just yet. Seems it's a bit more complicated than expected.

What do you mean by resized album art? If you're talking about album art that is not X by X, but ix more like X by Y, then it's not a problem. The script calculates the needed height and adjusts the picture accordingly. Check the attached files to see what I mean. I created those using a standalone version of the resize part.
Attached Images
File Type: jpg output.jpg (64.1 KB, 108 views)
File Type: jpg output2.jpg (23.1 KB, 89 views)
__________________

Last edited by parena; 04-01-2008 at 11:34 PM. Reason: extra screenshot
parena nincs online   Reply With Quote
Old 04-02-2008   #4
Member
 
Join Date: Oct 2007
Location: Finland
Posts: 137
Windows (well, DOS) version coming. I started creating a batch script by myself and I've got it working like this:

You place your album art on your M6 like you always do and start the script (after setting the right location for the MUSIC directory). You can also provide a background, just like the Linux version. The script will then find all .jpg files in the MUSIC directory structure and alter those. Woohoo!

I'm just trying to get rid of a few wrinkles (like positioning of the album image itself, which should have decimal calculations but that's not possible in DOS), but I have it working 100%
parena nincs online   Reply With Quote
Old 04-02-2008   #5
Moderator
 
BobbyQ's Avatar
 
Join Date: May 2007
Posts: 2,598
please no automatic scanning for covers ! (or at least as an option). Drag&Drop would be absolutely sufficient, so I can choose the covers to be converted by myself.
BobbyQ nincs online   Reply With Quote
Old 04-02-2008   #6
Member
 
Join Date: Oct 2007
Location: Finland
Posts: 137
Well, the thing I'm working on can be a base for someone else to create a gui for it. I'm a Linux guy and only use Windows to play games and for the meizu resource editor. For now, 2 scripts are needed. One wrapper that scans images and it calls the second one who actually does the converting, per file. So the ability is there already, it's just that someone needs to create that gui for it.
parena nincs online   Reply With Quote
Old 04-02-2008   #7
Moderator
 
BobbyQ's Avatar
 
Join Date: May 2007
Posts: 2,598
perfectly ok that way (for me). Please share what you got so far.
BobbyQ nincs online   Reply With Quote
Old 04-02-2008   #8
Member
 
Join Date: Oct 2007
Location: Finland
Posts: 137
First windows version is here. Check the original post.
parena nincs online   Reply With Quote
Old 04-03-2008   #9
Junior Member
 
Join Date: Oct 2007
Posts: 54
I'm using windows. I have followed your instructions: installed imagemagick (This version: ImageMagick-6.4.0-3-Q16-windows-dll.exe), connected the player to the pc. Then i have put all my album art in the music directory (My covers previously were in f:\ALBUMS directory, but i think i can modify the MUSICDIR directory in the first script to make it working in that way).
Open a dos windows, navigate to the folder in which the scripts are, and then i have write "meizu_albumart.bat".
Then on the video appears the following errors (I have put only one cover in the music directory to make this screen):




("Sintassi del comando errata" means "error in syntax command")


Where is my mistake?

Last edited by passero; 04-03-2008 at 06:29 PM.
passero nincs online   Reply With Quote
Old 04-03-2008   #10
Freshman
 
cwtim's Avatar
 
Join Date: Jul 2007
Location: Netherland
Posts: 20
hhm

same here on vista

composite: unable to open image
cwtim nincs online   Reply With Quote
Old 04-03-2008   #11
Moderator
 
BobbyQ's Avatar
 
Join Date: May 2007
Posts: 2,598
got the same error, so I debugged the "/" problem.
The following version features a simple drag+drop plan for single pictures while creating an automatic backup of the original cover.

Just a quick and dirty hack ... I am too tired today. But it works (good job parena btw !!!)
Attached Files
File Type: zip albumartfancy_dragndrop.zip (749 Bytes, 41 views)
BobbyQ nincs online   Reply With Quote
Old 04-03-2008   #12
Member
 
Join Date: Oct 2007
Location: Finland
Posts: 137
Updated to version 0.2 to fix the forward slash (/) bug. Really weird that it was giving problems. It works fine on my XP over here. Oh well...

Hope the drag and drop can get advanced, that'd be great. How does it work now? Just drop your albumart on top of the bat icon? Sorry for the people who have like 50 albums on their player. Or can you drop multiple files on it? Do you, afterwards, have to copy all those files to your player or do you connect the player and drop the files from there onto the icon?

Last edited by parena; 04-03-2008 at 09:53 PM.
parena nincs online   Reply With Quote
Old 04-04-2008   #13
Freshman
 
cwtim's Avatar
 
Join Date: Jul 2007
Location: Netherland
Posts: 20
it works with dragndrop (one by one), makes a new cover image and copies by it self.
i only dislike the black borders.
cwtim nincs online   Reply With Quote
Old 04-04-2008   #14
Member
 
Join Date: Oct 2007
Location: Finland
Posts: 137
Quote:
Originally Posted by cwtim View Post
it works with dragndrop (one by one), makes a new cover image and copies by it self.
i only dislike the black borders.
My version can use the background you want by giving it on the command line. However, you can alter BobbyQ's version by just setting the background you're using on the batch file itself, I guess. So, mine is automatic and does all your miniplayer's albumart, but BobbyQ's is a one by one version that now has a basis for expansion. I'd personally recommend using my version for now, unless you don't want to do all the covers on your miniplayer. But you're welcome to contribute, of course!
parena nincs online   Reply With Quote
Old 04-04-2008   #15
Passing By
 
shem's Avatar
 
Join Date: Mar 2008
Posts: 5
Can you post a step-by-step tutorial for windows users?
I'm a little confused about the steps to follow,i tried it for several times,i don't
know what i,m doing wrong, i don´t know nothing about MS-DOS commands
help me please !
Attached Images
File Type: jpg IMG001.JPG (65.5 KB, 45 views)
shem nincs online   Reply With Quote
Old 04-04-2008   #16
Freshman
 
cwtim's Avatar
 
Join Date: Jul 2007
Location: Netherland
Posts: 20
well, with drag and drop i get this error in dos.. (attachment)

and the cover still has black borders.. this is the line i edited in dragndrop.bat

tried them both

on pc.
IF EXIST "E:/Documenten van Tim/Mijn afbeeldingen/bg5.jpg" or
on meizu
IF EXIST "M:/PICTURES/ClearView/bg5.jpg"
Attached Images
File Type: jpg Naamloos.jpg (37.7 KB, 24 views)
cwtim nincs online   Reply With Quote
Old 04-04-2008   #17
Moderator
 
BobbyQ's Avatar
 
Join Date: May 2007
Posts: 2,598
Hi guys, mith parena's permission I will make a BatMan plugin for this nifty gadget. But right now I have a sh**load of other things to do, so that will take a while.
I am not a fan of the "convert all my covers on the Meizu at once without any way of restoring it to the pristine state" strategy. So, I will try to do it in a "do it / revert it" style. I do have a couple of ideas but no time :-/
__________________
BatMan, the free video converter for Meizu players. Problems ? English First Aid here. Deutsche Erste Hilfe hier.
Join the Meizume Chatroom at irc://dalnet/meizume ! Firefox Users : get the Chatzilla Plugin. Other Browsers : open a java chat at www.dal.net and enter "/join #meizume"
BobbyQ nincs online   Reply With Quote
Old 04-04-2008   #18
Member
 
Join Date: Oct 2007
Location: Finland
Posts: 137
Okay, all these errors with the drag and drop version I cannot do anything about, really, at the moment. Perhaps BobbyQ can give a hint or two.

For me it's not a problem that the thing would browse my miniplayer. The original album art is on your PC right? And having only some converted would look strange to me.

All I know is that my 'do them all' version works perfectly fine, also with a provided background. Just remember to call the meizu_albumart.bat file (after connecting your miniplayer and changing the paths to the correct locations) and not the other one. This is tested on XP only, though. I have no idea how Vista works with this kind of stuff. I'm not touching Vista. Hurts me enough to use XP.

And of course it's no problem to integrate this thing in BatMan. The more people can benefit, the better it is.
parena nincs online   Reply With Quote
Old 04-10-2008   #19
Passing By
 
Join Date: Sep 2007
Posts: 3
Great feature!! Nice job!!

Works on Vista, just edit the .bat-files, right-click meizu_albumart.bat and run it as administrator, next the cmd-screen popping up will stay empty and will disappear when ready..

Only problem: when you change the meizu background, the border of the album art doesn't match anymore..

Question: is there a way to increase the transpercy of the reflection? I no programmer so the code in the .bat's is all gibberish to me

Last edited by Pakkendu; 04-10-2008 at 01:18 PM.
Pakkendu nincs online   Reply With Quote
Old 04-10-2008   #20
Junior Member
 
Join Date: Apr 2007
Posts: 75
Does it have to be on a black background for the reflecction to work?
Sammy nincs online   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Bash script for conversion under Linux parena Video and Imaging 9 3 Weeks Ago 08:42 PM
Yet Another Mencoder Script wishmechaos Video and Imaging 16 08-24-2008 06:08 AM
Linux script for mencoder. shookie Video and Imaging 50 05-20-2008 09:10 PM
Batman / Mencoder script based conversion in windows hitman Video and Imaging 2 11-10-2007 12:10 PM
album artist tag conflicts with album tag wolffsed Technical 1 02-22-2007 09:11 PM


All times are GMT. The time now is 07:03 AM.


Powered by vBulletin. Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0 ©2008, Crawlability, Inc.
 
Meizu Me is an independent resource for all things Meizu. Meizu, Mini Player, Music Card, Mini One and all other related names are properties of MEIZU Inc. All content © 2008 Meizu Me. All Rights Reserved.