MCPcopy Create free account
hub / github.com/GrapheneCt/NetStream / VodOpenFileImpl

Method VodOpenFileImpl

NetStream/source/players/player_av.cpp:387–416  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

385}
386
387int32_t AVPlayer::SmoothStreaming::VodOpenFileImpl(const char *argFilename)
388{
389 int32_t ret = SCE_OK;
390
391 SCE_DBG_LOG_INFO("[VodOpenFileImpl] VodOpenFileImpl: %s", argFilename);
392
393 if (!sce_paf_strncmp(argFilename, "localfile:", 10))
394 {
395 m_vod = LocalFile::Open(argFilename + 10, File::RDONLY, 0, &ret);
396 }
397 else
398 {
399 m_vod = CurlFile::Open(argFilename, File::RDONLY, 0, &ret, NULL, utils::GetGlobalProxy());
400 }
401 if (ret < 0)
402 {
403 return -1;
404 }
405
406 m_vodBuf = MallocBuffer::Allocate(SCE_KERNEL_16MiB);
407 m_prVod = new PredictiveFile(m_vodBuf);
408
409 ret = m_prVod->Open(m_vod);
410 if (ret < 0)
411 {
412 return -1;
413 }
414
415 return 0;
416}
417
418int32_t AVPlayer::SmoothStreaming::VodCloseFileImpl()
419{

Callers 1

GetVODReplacementMethod · 0.80

Calls 1

OpenMethod · 0.45

Tested by

no test coverage detected