Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: foo_cwb_hooks (Read 302213 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

foo_cwb_hooks

Reply #200
This is a really stupid question, but now that I've set up foo_custominfo with a DATE ADDED field, how do I actually get Foobar to update my music and populate it with that information?

foo_cwb_hooks

Reply #201
bump


foo_cwb_hooks

Reply #203
Hey cwbowron,

Do you have an idea when the created date function will become available?

Thanks!

foo_cwb_hooks

Reply #204
Hello , a beginner question : where can I use the plugin functions and variables?
I tried using them in global variables in ui_columns and in foo_playlist_tree with no luck.


Edit: I got it to work in playlist_tree but what about ui_columns? Is it possible to use it in globals?

foo_cwb_hooks

Reply #205
I notice that the wiki page says not to request any new features along the lines of %cwb_next_*%, but since %cwb_next_title%, etc. are in existence, is it possible to have any kind of "previous" function? Or there is already a way to do it that I'm not aware of?


second!  cwb_previous_artist/album would be nice!

also, is there a way to have cwb_next_* apply individual playlist entries, not just whats currently playing?

foo_cwb_hooks

Reply #206
Hi, cwbowron!

Would it be possible for you to make available for download the last release of foo_cwb_hooks that was compatible with foobar v0.8.3? Or was there ever one?

I can't switch to v0.9.x because a crucial plug-in does not support it ( foo_dsp_continuator ). But I really, really would like to be able to access the status of "stop after current" for title formatting.

foo_cwb_hooks

Reply #207
Would it be possible for you to make available for download the last release of foo_cwb_hooks that was compatible with foobar v0.8.3? Or was there ever one?


foo_cwb_hooks was new for 0.9
There used to be a link to my website here.

foo_cwb_hooks

Reply #208
Should all of the functions from cwb_hooks work with Autoplaylist formatting?

foo_cwb_hooks

Reply #209
great plugin!

just a couple of quick questions:

- is it simple to implement a function like %_filesize% but for all currently selected tracks (%cwb_activelist_filesize% and %cwb_selection_filesize% ). Would be nice to see the overall size before sending the files to DAP devices. + analogue of %cwb_playinglist_count% but for selected items %cwb_selection_count% would be nice as well.

- any chance to have another function for querying the queued stack to get artist/album/track for each particular queued item etc.

Thanks in advance!

 

foo_cwb_hooks

Reply #210
I would love to have a variable like %playback_start% that contains the date and time of when I started listening to the song.

also all date and time functions should be available in pure seconds, like convert 2007.26.1 23:55 in a timestamp in seconds, with which I can do arihmatic operations on. that would also be nice to have.

thx

foo_cwb_hooks

Reply #211
I would love to have a variable like %playback_start% that contains the date and time of when I started listening to the song.


I could do that, but based on your other posts, what you really want is when the track was scrobbled... Why not ask the author of the scrobble plugin to just make a way to tag the music when it was last scrobbled, rather than have me implement something that you have to half-ass to get to do what you really want?
There used to be a link to my website here.

foo_cwb_hooks

Reply #212
its just the heck and fun of doing it yourself
anyway, I still think it still is useful information, others might be happy to have...
anyway, yeah, why not ask in the audioscrobbler topic, its sure the easiest but also the most lame xD

foo_cwb_hooks

Reply #213
i second the request of crazymad! I'd love to add the the information to my progressbar so I could see when the track started playing but also when it will be finished...

something like
Code: [Select]
============--------------------
09:23:11                09:26:43


That way I wouldn't forget time that fast or the pizza in my oven

foo_cwb_hooks

Reply #214
heres another request, hope I am not a brag ^^ :

you implemented two user definable variables for the next track in the playlist. could you do the same for the previous track? that would be sweet!
thx

EDIT: I just played around with %cwb_next_user1% variable assigning it to %album% (as been done by default) and cant seem to get it to work right with Columns UI (in 'Playlist View' -> Globals), to color and group all songs belonging to the same album:

I though it could start with the first entry in the playlist, checking %cwb_next_user1% and compare it to the %album% of the current entry to see if the next song still belongs to the same album.
but it updates the information %cwb_next_user1% on a specific entry only when this entry has been played. if it hasnt been played before, it has the same information stored in %cwb_next_user1% as the current playing song, when this particular song has been added to the playlist, and keeps it, unil it has been played.
I hope this is understandable...

foo_cwb_hooks

Reply #215
No, %cwb_next_*% gets the next track to be played.

As for colouring each album differently then I use this.
Code: [Select]
$set_global(album_colour,$hsl($mod($div($crc32($if3(%musicbrainz_albumid%,%musicbrainz album id%,%live%,%album%,'1')),240),220),160,100)
)

$set_global(album_colour2,$hsl($mod($add($mod($div($crc32($if3(%musicbrainz_albumid%,%musicbrainz album id%,%live%,%album%,'1')),240),220 ),128),256),150,120)
)
It changes the hue of the colour depending on the album or '1' if no album is present. (The numbers are more or less 'magic'.)


i second the request of crazymad! I'd love to add the the information to my progressbar so I could see when the track started playing but also when it will be finished...

something like
Code: [Select]
============--------------------
09:23:11                09:26:43


That way I wouldn't forget time that fast or the pizza in my oven

If there was an $date_add and $date_sub then you could do this using %cwb_systemdate%.

foo_cwb_hooks

Reply #216
Quote
No, %cwb_next_*% gets the next track to be played.

I see the problem.
I also thought UI Columns would go through the entries in the playlist like a loop, and I would be able to alter global variables for later uses in different entries of the playlist. but all this isnt the case...

since I wanted to colour the background of the album, your script is going to create a very colorfull foobar appearance. I was thinking more of two colors alternating.

and since all this loop thinking of mine is incorrect, I guess %cwb_prev_*% is useless, too...

foo_cwb_hooks

Reply #217
cwbowron can you modify the $cwb_fileexists method this way that it allows using wildcards?

Thats what I want to do with it:

if  ( Fileexists in same folder: *.cue AND Subsongindex = 0 AND Length > 20min)
Then    Skip
Else    Play


edit: I have tested this condition with foo_skip and it works: $ifgreater(%length_seconds%,3600,1,0)
but until I cannot test if a cue is present in folder it skips also live-mixes without cues.

foo_cwb_hooks

Reply #218
How do I use the %cwb_queueindex%. I would like to highlight the tracks currently in the queue in a browser playlist which is not the currently playing playlist.

As a simple test I tried this in the Item Display code of a SCPL

Code: [Select]
$ifequal($mod(%_playlist_number%,2),0,
$drawrect(0,0,0,0,brushcolor-$if(%_selected%,64-64-64 pencolor-60-60-60,33-33-33 pencolor-27-27-27))
,
$drawrect(0,0,0,0,brushcolor-$if(%_selected%,74-74-74,40-40-40) pencolor-null)
)

$if(%cwb_queueindex%,$drawrect(0,0,0,0,brushcolor-255-255-255 pencolor-null),)


This code does not work if the browser playlist is active, nor if the playing playlist is active. The SCPLs are panels in a PanelsUI layout.

foo_cwb_hooks

Reply #219
Hi, cwbowron!


It is possible add function to compare dates as in cwb_datediff() function, but arguments format is equal format of tag "last_played_timestamp".

Or add function to convert "last_played_timestamp" to "yyyy-mm-dd hh:mm:ss".

foo_cwb_hooks

Reply #220
How do I use the %cwb_queueindex%.


Using 1.1beta [Dec 1 2006 - 13:47:34] I am now pretty sure that this variable is not working with this version. It does not act as a boolean to $drawrect(), nor does it display anything under any circumstances. Is anyone using this variable? If it works for you, which version of cwb_hooks are you using, and are there any prerequisites for it to work?

foo_cwb_hooks

Reply #221
Works fine for me, same component version with foobar 0.9.4.2. It has been working since as long as I can remember so don't know if there is any prerequisite and I don't think so only foobar 0.9 is needed.

foo_cwb_hooks

Reply #222
Works fine for me, same component version with foobar 0.9.4.2.


Thanks for the reply, can you possibly give me a titleformatting snippet that demonstrates that it works? I am currently in the process of investigating the SDK to figure out how to extend titleformatting which is proving a little more painstaking then I hoped.

foo_cwb_hooks

Reply #223
This is what I'm using
Code: [Select]
$ifgreater(%cwb_queuelength%,1,
'['%cwb_queueindexes%/%cwb_queuelength%']',
'['%cwb_queueindex%']'))

foo_cwb_hooks

Reply #224
This is what I'm using
Code: [Select]
$ifgreater(%cwb_queuelength%,1,
'['%cwb_queueindexes%/%cwb_queuelength%']',
'['%cwb_queueindex%']'))

It's the strangest thing, first there is one extra ) in the code snippet, but in any case, all I get is "[]" as output. I have no idea, back to the drawing board.