Initial community commit
This commit is contained in:
parent
537bcbc862
commit
fc06254474
16440 changed files with 4239995 additions and 2 deletions
28
Src/replicant/http/HTTPPlaybackService.cpp
Normal file
28
Src/replicant/http/HTTPPlaybackService.cpp
Normal file
|
@ -0,0 +1,28 @@
|
|||
#include "HTTPPlaybackService.h"
|
||||
#include "player/ifc_player.h"
|
||||
#include "player/ifc_playback.h"
|
||||
#include "HTTPPlayback.h"
|
||||
#include "nx/nxpath.h"
|
||||
#include "nswasabi/ReferenceCounted.h"
|
||||
|
||||
int HTTPPlaybackService::PlaybackService_CreatePlayback(unsigned int pass, nx_uri_t filename, ifc_player *player, ifc_playback **out_playback_object)
|
||||
{
|
||||
if (NXPathProtocol(filename, "http") == NErr_Success)
|
||||
{
|
||||
HTTPPlayback *http_playback = new ReferenceCounted<HTTPPlayback>;
|
||||
if (!http_playback)
|
||||
return NErr_OutOfMemory;
|
||||
|
||||
int ret = http_playback->Initialize(filename, player);
|
||||
if (ret != NErr_Success)
|
||||
{
|
||||
http_playback->ifc_playback::Release();
|
||||
return ret;
|
||||
}
|
||||
|
||||
*out_playback_object = http_playback;
|
||||
return NErr_Success;
|
||||
}
|
||||
return NErr_False;
|
||||
}
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue