Add file to gapless queue. (UNICODE version)
virtual __stdcall int AddFileW(const wchar_t * sFileName, TStreamFormat nFormat) = 0;
Parameters |
Description |
const wchar_t * sFileName |
Pointer to a UNICODE null-terminated string that specifies the name of the file. |
TStreamFormat nFormat |
Stream format. Use sfAutodetect if you need to autodetect stream format of specified file. |
Return Values |
Description |
1 |
All OK. |
0 |
Error. To get error message read here. |
All streams added to gapless queue will play without gap between these streams. When one stream ends, next stream from queue starts playing without interruption. Position marker is set to 0 for each stream from queue. This means that when one stream ends, position is set to 0 for next stream. Position is not cumulated.
First you need to open one song. Then add second song to gapless queue, then third, ...
You can clear gapless queue with Close or zplay_Close function.
Play gapless 3 songs.
// open first song instance->AddFileW(L"myFirstSong.mp3", sfAutodetect); // then add second song to gapless queue instance->AddFileW(L"mySecondSong.mp3", sfAutodetect); // then add third song to gapless queue instance->AddFileW(L"myThirdSong.ogg", sfAutodetect);
// open first song zplay_AddFileW(instance, L"myFirstSong.mp3", sfAutodetect); // then add second song to gapless queue zplay_AddFileW(instance, L"mySecondSong.mp3", sfAutodetect); // then add third song to gapless queue zplay_AddFileW(instance, L"myThirdSong.ogg", sfAutodetect);
Copyright (c) 2010. Zoran Cindori - All rights reserved.
Web: http://libzplay.sourceforge.net/ Email: zcindori@inet.hr |