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_stopafteralbum (Read 23894 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

foo_stopafteralbum

Following the forum rules, discussion for this topic here:

simple principle: tracknumber = totaltracks -> stop after current
A little bit too simple IMHO. You assume that an album will always be played in tracknumber order and that the last track of an album is available. Further, depending on the numbering scheme you use for multi-disc albums, it will also not work, if totaltracks = number of all tracks, but the tracks of the discs are numbered per disc.

 

foo_stopafteralbum

Reply #1
Thanks for feedback.

it is not necessary to play album in tracknumber order. only last track is decisive for stop. component should work for complete albums.
multi-disc albums problem could probably be solved, but playing last track of each disc is also mandatory here.
I'm thinking about something like max(tracknumberold, tracknumber) for disc1 etc. and subtracting this value from totaltracks.

by the way: heard about problem "Failed to load DLL: foo_stopafteralbum.dll Reason: This component is missing a required dependency, or was made for different version of foobar2000." on some environments. I'm a novice in component development. I did run "dependency walker" for foo_stopafteralbum and found dependencies Kernel32.dll, OLEaut32.dll and MSVCR100.dll and subdependencies. Is this ok? (vc10/vista32bit/SDK 2010-05-21)

foo_stopafteralbum

Reply #2
by the way: heard about problem "Failed to load DLL: foo_stopafteralbum.dll Reason: This component is missing a required dependency, or was made for different version of foobar2000." on some environments. I'm a novice in component development. I did run "dependency walker" for foo_stopafteralbum and found dependencies Kernel32.dll, OLEaut32.dll and MSVCR100.dll and subdependencies. Is this ok? (vc10/vista32bit/SDK 2010-05-21)
As you are probably using a German Visual C++ 2010, you should set the following to get rid of the dependency for msvcr100.dll (probable English equivalents in brackets):
Right click on your project and choose the following path
-> Eigenschaften (Properties)
-> Konfigurationseigenschaften (Configuration properties)
-> C/C++
-> Codegenerierung (Code generation)
-> Laufzeitbibliothek (Run time library)
-> Multithreaded (/MT)

foo_stopafteralbum

Reply #3
Muliithreaded (/MT) was/is activatated on my builds.

Can nevertheless get rid of msvcr100.dll dependency on build of WIN32 release.

Ignoring msvcrt.lib figures out the problem:

Quote
1>------ Erstellen gestartet: Projekt: foo_stopafteralbum, Konfiguration: Release Win32 ------
1>LINK : warning LNK4075: /INCREMENTAL wird aufgrund der Angabe von /OPT:ICF ignoriert.
1>  pfc.lib(string.obj) : Es wurde ein mit /GL kompiliertes MSIL .netmodule oder module gefunden. Verknüpfung wird mit /LTCG erneut gestartet. Fügen Sie /LTCG zur Linkbefehlszeile hinzu, um die Linkerleistung zu erhöhen.
1>LINK : warning LNK4075: /INCREMENTAL wird aufgrund der Angabe von /LTCG ignoriert.
1>    Bibliothek "C:\Users\****\Documents\Visual Studio 2010\Projects\fb2k3\foobar2000\foo_stopafteralbum\Release\foo_stopafteralbum.lib" und Objekt "C:\Users\****\Documents\Visual Studio 2010\Projects\fb2k3\foobar2000\foo_stopafteralbum\Release\foo_stopafteralbum.exp" werden erstellt.
1>pfc.lib(guid.obj) : error LNK2001: Nicht aufgelöstes externes Symbol "__imp__strchr".
1>foobar2000_SDK.lib(filesystem.obj) : error LNK2001: Nicht aufgelöstes externes Symbol "__imp___wfopen".

1>C:\Users\****\Documents\Visual Studio 2010\Projects\fb2k3\foobar2000\foo_stopafteralbum\Release\foo_stopafteralbum.dll : fatal error LNK1120: 2 nicht aufgelöste externe Verweise.
========== Erstellen: 0 erfolgreich, Fehler bei 1, 4 aktuell, 0 übersprungen ==========

foo_stopafteralbum

Reply #4
As you already detected, ignoring msvcrt.lib is not a solution, but as far as I remember VC2010 is setting runtime library setting to Multithreaded-Dll (/MD), while converting the SDK-projects to VC2010 format. So, you should also check the four SDK projects for this setting.


foo_stopafteralbum

Reply #6
Thanks for the component.
Could you also make repeat album, instead of stop something like go back totaltrack - 1. It would be awesome.



foo_stopafteralbum

Reply #9
Can you add stop after queue? i have component for this, but i want all in one


foo_stopafteralbum

Reply #11
Could you uncheck stop after current after all actions have been taken.
I think it's conventional to restore the initial state and it could solves bunch of weird behavior, atleast in my case.


My setting: Order is default. Cursor follows playback checked, stopafteralbum default setting.

1. Stop after album, repeat album checked
Playback cursor does go back from last song to the first, but after that the first song is being repeated.

2. Stop after album, skip album checked
After finishing the last song of album 1 playback skips album 2 then plays first song of album 3 then skips the rest of album 3 and plays 1st song of album 4 and so on.

I noticed stop after current is still checked, so after I uncheck it, playback works how it should again.

foo_stopafteralbum

Reply #12
Maybe these problems are because Preferences | Playback | Stops playback after current track | Reset when stopping is not activated.

(Stops playback after current track deactivated)

foo_stopafteralbum

Reply #13
Awesome! I didn't know that option. But it works perfectly now.
Thanks.


foo_stopafteralbum

Reply #15
great component! how did i ever miss this!!!?
But... i have encountered some problems with it.
The Random Album and the Skip Album options work in a weird fashion.
in my case:
> if i choose Random Album, then after the current album's last track is played, it goes to the immediate next album but then goes back to the previous and starts going up to the first track of the album (the one which i just finished listening to)
> if i choose Skip Album, then after the current album's last track is played, it goes to the immediate next album, skips 2 tracks and plays the third track. and that's the end of this option's use after which it will still be shown as checked but i don't find any difference in the playing order or sequence.

i suppose i must be doing something majorly wrong so forgive my lapses since i just installed this component.

also, can you implement these options:
> a panel as big as a button (but still sizeable). On a right-click, it should provide all your options.
or
> as a drop down box like the playlist order or like foo_uie_playlists_dropdown
and
> cascade your options in it's own context menu (like playback > order) since you have provided so many options.

imo, it could get less messy and also become easy to access.

--
fyi: my playlist order is set to default and the cursor follows playback (if these even matter)

foo_stopafteralbum

Reply #16
> if i choose Random Album, then after the current album's last track is played, it goes to the immediate next album but then goes back to the previous and starts going up to the first track of the album (the one which i just finished listening to)

I don't understand. You played last track, and then first track? Thats normal, random number generator found trackno. 1 after playing last track. Cursor goes for a moment to first track of next album, because I use (buildin) "Stop after current" as trigger for action.

> if i choose Skip Album, then after the current album's last track is played, it goes to the immediate next album, skips 2 tracks and plays the third track. and that's the end of this option's use after which it will still be shown as checked but i don't find any difference in the playing order or sequence.

Maybe wrong tagging? (3/2 tracknumber/totaltracks)
I've tested it here with several albums: whole next album ist skipped.

> a panel as big as a button (but still sizeable). On a right-click, it should provide all your options.
or
> as a drop down box like the playlist order or like foo_uie_playlists_dropdown

Both are good idea's for new (stand alone) components making mainmenu commands in general easier accessible.
(1st one can by realized with WSH panel too)

> cascade your options in it's own context menu (like playback > order) since you have provided so many options.

Done. (efficient, because I want to add some more mainmenu commands)


foo_stopafteralbum

Reply #17
Haven't got much time to check why it behaves weird for me but see...
what i do to observe the effect of the option Random Album is:
> I play the last track of an album (say PQR)
> Enable the option "Random Album"
> Let this track complete

now... what happens is:
> the cursor goes to the first track of the next album in the playlist but without playing anything, it quickly goes back to the last track of the previous album (the one i just listened to). It doesn't play this one either but continues to go up till the first track of the album PQR and then, it starts playing this track.

note: playlist has many albums

i tend to be stupid but seriously... what should the Random Album option actually do?

--
PS: incorrect tags are almost impossible to find in my library


foo_stopafteralbum

Reply #19
ah! random album... track!
i presumed something else

well... now i see it working!

foo_stopafteralbum.dll

Reply #20
When I check  "Control-Stop after track- Number" my foobar don't stop after playing "Number" tracks.

If I check "Control-Stop after album" and when tracknumber=totaltrack  then foobar stop.

Explain to me how to stop playing through the N tracks. I use last version of plugin - 1.7.

I solve problem. I use "playlist attributes - remove played tracks". When I uncheck this future foobar stop after N tracks normally.

foo_stopafteralbum

Reply #21
bug? this component resets foobar "Stop playback after the current track" regardless user preference

foo_stopafteralbum

Reply #22
This component seems to be really promising, unfortunately the documentation is perhaps a bit too brief...
A help file/text with whole english sentences would be nice. Perhaps the option names could be made a bit more verbose! What are those "-N" (N=1..7) suffixes?

Re: foo_stopafteralbum.dll

Reply #23
Nice work dude!  Perhaps you could include a "skip to next playlist on last in playlist" option? Since you already have stop after last track and next playlist after album, I would guess it's just a matter of combining those two? Just in case I make a playlist with multiple albums (that does happen sometimes...). 

Also, it doesn't seem to detect when a new version is out with the updater? Dunno how that works exactly, but just a heads up.

Hmm, is there a discussion thread for this component? I suppose this post should go there...

foo_stopafteralbum

Reply #24
Your component is great but could you add the option to execute it only one (and then "reset" its setting, as the stop after current function does in foobar)?

For example I am listening to a playlist and I want to stop listening to it 2 tracks later. With your component I can do it easily but after that, it will always stop every 2 tracks (until I manually uncheck the option)


By the way I think there is a bug with "stop after track 1", because when I select it, play won't stop after the current playing track but after the following track.

Best regards,
Decalicatan Decalicatan

Decalicatan Decalicatan