I was testing out dragging and dropping tracks in the playlist window, and I really don't like the way the window draws as you drag tracks. If you are viewing a playlist grouped by %album%, and you drag one track up, when the window draws the track in the next index position, it redraws the group header so you have to move your mouse over the group header once again to move the track one more index. This is especially annoying when you are dragging one track and if your "group rows" is set to more than 1, you must move your mouse more distance.
The problem is not as annoying but also present when you are dragging multiple tracks. A solution I thought of while messing around would be to re-draw the item displays as long as your mouse button (or alt) are "down," but only re-draw the group headers when your mouse button (or alt) is "up." In other words, don't refresh group headers while dragging.
I hope you can understand my idea because I'm not sure if I'm being clear. I really would like this to be an option.
EDIT: I just noticed that when you are dragging a track down in the list, that is to say increasing it's list index, and it's directly above a group header, it will refresh in the next highest list index position when your mouse cursor first crosses the group header below the track. I like this behavior. When you drag a track up in the list (decrease it's index) and it's directly BELOW a group header, it will not refresh until the mouse cursor crosses the top of the group header. This is very annoying, especially if that track has it's own group header, every time you decrease it's index and it re-draws in the window, you must move your mouse over the entire group header. It behaves much more smoothly when it's being dragged down, and it would be a nice fix if it behaved like that when you dragged it up, too.
**********************************************************
I've found another problem which I would consider to be a general performance problem of this plugin. When I am using this component with my config, the re-draw rate while resizing the window varies according to how many album images I am displaying. I will include my code for an example at the end of the post. When the SCP view has a small height and I am only showing 1 group header, that is to say only showing 1 album art jpg, the window redraws quickly and smoothly. If I increase the height so that two group headers are showing, the redraw rate slows down considerably, but still follows the mouse cursor well. If I increase the height even more so that three JPGs are showing, the re-draw rate drops to about 2 fps and it makes the mouse cursor visibly lag. The jpgs I have for covers are no bigger than 300x300 or 800kB, and I have a 3.4ghz processor with 2gigs of dual channel ram, 512 meg PCIe video card. In order to try and get better perfomance I even renamed all of my album art from "%artist%\%album%\folder.jpg" to "album art\%artist% - %album%.jpg" and put all of my art in a central folder to see if seek times of my hard disk might be limiting my performance. Now, they are all in one folder and defragmented, yet I still have very slow screen refresh rates when displaying more than 2 JPGs. The other images displayed are all under 4k each.
I commented my code thoroughly which I notice nobody around here does. I hope it helps anyone understand my problem.
SCP Code:
row height:15
group rows:3
group by: %album%
item display
// initialize variables needed to properly display dynamically resizing album art.
// imgwidth = the desired width of the entire composite image, art+jewel case
// imgheightfac*imgwidth/10=imageheight
// artdimfac*imgwidth/10=artwidth and artheight
// artvoffsetfac*imgheight/100 = the vertical offset of the album art from the top of the group display
// arthoffsetfac*imgwidth/100 = the horizontal offset of the album art
// grouprows = number of rows in the group
// compositeoffset takes into account the width of the album year and makes sure the composite doesn't run into the year
$puts(imgwidth,100)
$puts(imgheightfac,9)
$puts(artdimfac,83)
$puts(artvoffsetfac,45)
$puts(arthoffsetfac,120)
$puts(grouprows,3)
$puts(compositeoffset,37)
// calculating variables needed from the initialized variables
// imgheight the cropped height of the
// artdim = the dimensions of the album art within the case/disc/art composite
// ralignoffset = how far from the right window border the image renders, 45 = pixel width of the year display.
// ralignoffsetart = how far from the right window border the art renders (slightly more to the right than the whole image)
// artvoffset = the vertical offset of the art so it appears centered in the case
$puts(imgheight,$div($mul($get(imgheightfac),$get(imgwidth)),10))
$puts(artdim,$div($mul($get(artdimfac),$get(imgwidth)),100))
$puts(ralignoffset,$sub(%_width%,$add($get(imgwidth),$get(compositeoffset))))
$puts(ralignoffsetart,$add($sub(%_width%,$add($get(imgwidth),$get(compositeoffset))),$div($mul($get(arthoffsetfac),$get(imgwidth)),1000)))
$puts(artvoffset,$div($mul($get(imgheight),$get(artvoffsetfac)),1000))
$ifequal($mod(%_itemindex%,2),0,
$imageabs(,,\images\LE5\reluna1.png,),
$imageabs(,,\images\LE5\reluna2.png,))
$if(%_selected%,$imageabs(,,\images\LE5\relunagreen.png,),)
$if(%isplaying%,$imageabs(,,\images\LE5\relunablue.png,),)
$if(%isplaying%,$font(Calibri,8,bold,0-0-200),$font(Calibri,8,,0-0-0))
$padding(4,)
$align(right,middle)
$if(%isplaying%,%_time_remaining%,%length%)
$padding(2,)
$align(left,middle)
%tracknumber%
$padding(22,)
$align(left,middle)
[%title%]
$ifgreater($mul(%_height%,%_itemcount%),40,
$imageabs2($get(imgwidth),$get(imgheight),,$sub($mul(%_height%,$add(%_itemindex%,$get(grouprows))),$add(%_height%,1)),,%_height%,$get(ralignoffset),,/images\test\case.png,)
//$imageabs2($get(imgwidth),$get(imgheight),,$sub($mul(%_height%,$add(%_itemindex%,$get(grouprows))),$add(%_height%,1)),,%_height%,$get(ralignoffset),,/images\test\disc.png,)
$imageabs2($get(artdim),$get(artdim),,$sub($mul(%_height%,$add(%_itemindex%,$get(grouprows))),$add(%_height%,$get(artvoffset))),,%_height%,$get(ralignoffsetart),,d:\album art\%artist% - %date% - %album%.jpg,)
,)
group display
// initialize variables needed to properly display dynamically resizing album art.
// imgwidth = the desired width of the entire composite image, art+jewel case
// imgheightfac*imgwidth/10=imageheight
// artdimfac*imgwidth/10=artwidth and artheight
// artvoffsetfac*imgheight/100 = the vertical offset of the album art from the top of the group display
// arthoffsetfac*imgwidth/100 = the horizontal offset of the album art
// grouprows = number of rows in the group
// compositeoffset takes into account the width of the album year and makes sure the composite doesn't run into the year
$puts(imgwidth,100)
$puts(imgheightfac,9)
$puts(artdimfac,83)
$puts(artvoffsetfac,45)
$puts(arthoffsetfac,120)
$puts(grouprows,3)
$puts(compositeoffset,37)
// calculating variables needed from the initialized variables
// imgheight the cropped height of the
// artdim = the dimensions of the album art within the case/disc/art composite
// ralignoffset = how far from the right window border the image renders, 45 = pixel width of the year display.
// ralignoffsetart = how far from the right window border the art renders (slightly more to the right than the whole image)
// artvoffset = the vertical offset of the art so it appears centered in the case
$puts(imgheight,$div($mul($get(imgheightfac),$get(imgwidth)),10))
$puts(artdim,$div($mul($get(artdimfac),$get(imgwidth)),100))
$puts(ralignoffset,$sub(%_width%,$add($get(imgwidth),$get(compositeoffset))))
$puts(ralignoffsetart,$add($sub(%_width%,$add($get(imgwidth),$get(compositeoffset))),$div($mul($get(arthoffsetfac),$get(imgwidth)),1000)))
$puts(artvoffset,$div($mul($get(imgheight),$get(artvoffsetfac)),1000))
//chooses album artist over track artist for the entire header
$if(%album artist%,$put(artist,%album artist%),$put(artist,%artist%))
// the background image
$imageabs(,,\images\LE5\relunaorange2.png,)
// the genre image
$imageabs($sub($get(ralignoffset),53),2,\images\ojoink\%genre%.gif,)
//this section renders the album artist, album title
$alignabs(6,4,%_width%,20,left,top)
$font(Calibri,12,bold glow-255-255-255 glowexpand-1,0-0-0)
$get(artist)
$font(Calibri,11,bold glow-255-255-255 glowexpand-0,0-0-0)
$alignabs(6,20,%_width%,20,left,bottom)
%album%
// this section renders the date, codec, and bitrate
$font(Calibri,12,glow- glowexpand-0 glowalpha-15,40-40-40)
$alignabs($sub(%_width%,$add($calcwidth(%date%),4)),2,%_width%,20,left,)
%date%
$font(Calibri,8,glow- glowexpand-0 glowalpha-15,40-40-40)
$alignabs($sub(%_width%,$add($calcwidth(%codec%),5)),19,%_width%,20,left,)
%codec%
$alignabs($sub(%_width%,$add($calcwidth(%bitrate%),5)),29,%_width%,20,left,)
%bitrate%
// renders the album art
$ifgreater($mul(%_height%,%_itemcount%),90,
$imageabs2($get(imgwidth),$get(imgheight),,,,,$get(ralignoffset),,/images\test\case.png,)
//$imageabs2($get(imgwidth),$get(imgheight),,,,,$get(ralignoffset),,/images\test\disc.png,)
$imageabs2($get(artdim),$get(artdim),,,,,$get(ralignoffsetart),$get(artvoffset),d:\album art\%artist% - %date% - %album%.jpg,)
,)