/foundation/multimedia/player_framework/frameworks/native/player/test/unittest/src/ |
D | player_unit_test.cpp | 43 player_ = std::make_shared<PlayerMock>(callback_); in SetUp() 44 ASSERT_NE(nullptr, player_); in SetUp() 45 EXPECT_TRUE(player_->CreatePlayer()); in SetUp() 46 EXPECT_EQ(MSERR_OK, player_->SetPlayerCallback(callback_)); in SetUp() 51 if (player_ != nullptr) { in TearDown() 52 player_->Release(); in TearDown() 59 if (player_ != nullptr) { in PlayFunTest() 60 EXPECT_EQ(MSERR_OK, player_->GetDuration(duration)); in PlayFunTest() 61 EXPECT_EQ(MSERR_OK, player_->Play()); in PlayFunTest() 62 EXPECT_TRUE(player_->IsPlaying()); in PlayFunTest() [all …]
|
D | player_mock.cpp | 330 player_ = PlayerFactory::CreatePlayer(); in CreatePlayer() 331 return player_ != nullptr; in CreatePlayer() 336 UNITTEST_CHECK_AND_RETURN_RET_LOG(player_ != nullptr, -1, "player_ == nullptr"); in SetSource() 338 int32_t ret = player_->SetSource(url); in SetSource() 345 return player_->SetSource(fd, offset, size); in SetSource() 350 UNITTEST_CHECK_AND_RETURN_RET_LOG(player_ != nullptr, -1, "player_ == nullptr"); in SetSource() 368 int32_t ret = player_->SetSource(fd, offset, length); in SetSource() 385 return player_->SetSource(dataSrc_); in SetDataSrc() 390 …UNITTEST_CHECK_AND_RETURN_RET_LOG(player_ != nullptr && callback_ != nullptr, -1, "player or callb… in Prepare() 392 int32_t ret = player_->Prepare(); in Prepare() [all …]
|
/foundation/multimedia/media_lite/frameworks/player_lite/binder/ |
D | player.cpp | 40 player_ = PlayerClient::GetInstance(); in Player() 52 CHK_NULL_RETURN(player_); in SetSource() 53 ret = player_->SetSource(source); in SetSource() 69 CHK_NULL_RETURN(player_); in Prepare() 70 return player_->Prepare(); in Prepare() 76 CHK_NULL_RETURN(player_); in Play() 77 return player_->Play(); in Play() 83 if (player_ == nullptr) { in IsPlaying() 87 return player_->IsPlaying(); in IsPlaying() 93 CHK_NULL_RETURN(player_); in Pause() [all …]
|
/foundation/multimedia/media_lite/frameworks/player_lite/passthrough/liteplayer/ |
D | player.cpp | 29 player_ = PlayerClient::GetInstance(); in Player() 41 if (player_ == nullptr) { in SetSource() 45 ret = player_->SetSource(source); in SetSource() 62 if (player_ == nullptr) { in Prepare() 66 return player_->Prepare(); in Prepare() 72 if (player_ == nullptr) { in Play() 76 return player_->Play(); in Play() 82 if (player_ == nullptr) { in IsPlaying() 86 return player_->IsPlaying(); in IsPlaying() 92 if (player_ == nullptr) { in Pause() [all …]
|
/foundation/multimedia/player_framework/test/fuzztest/player_fuzztest/playerfile_fuzzer/ |
D | playerfile_fuzzer.cpp | 40 player_ = OHOS::Media::PlayerFactory::CreatePlayer(); in FuzzFile() 41 if (player_ == nullptr) { in FuzzFile() 45 player_->SetPlayerCallback(cb); in FuzzFile() 57 player_->SetVideoSurface(producerSurface); in FuzzFile() 58 player_->PrepareAsync(); in FuzzFile() 60 player_->Play(); in FuzzFile() 62 player_->Pause(); in FuzzFile() 63 player_->Seek(3000, SEEK_NEXT_SYNC); // seek 3000 ms in FuzzFile() 64 player_->SetVolume(0.5, 0.5); // leftVolume is 0.5, rightVolume is 0.5 in FuzzFile() 66 player_->GetCurrentTime(time); in FuzzFile() [all …]
|
/foundation/arkui/ace_engine/frameworks/core/components_ng/render/adapter/ |
D | media_player_impl.cpp | 35 if (player_) { in ~MediaPlayerImpl() 36 player_->Stop(); in ~MediaPlayerImpl() 37 player_->Release(); in ~MediaPlayerImpl() 61 player_ = AceType::MakeRefPtr<Player>(context, std::move(errorCallback)); in CreateMediaPlayer() 63 player_->Create(nullptr); in CreateMediaPlayer() 121 player_->AddPreparedListener(onPrepared); in InitListener() 122 player_->AddPlayStatusListener(onPlayerStatus); in InitListener() 123 player_->AddCurrentPosListener(onCurrentTimeChange); in InitListener() 124 player_->AddCompletionListener(onCompletion); in InitListener() 131 return player_ != nullptr; in IsMediaPlayerValid() [all …]
|
D | media_player_impl.h | 61 RefPtr<Player> player_; variable
|
/foundation/multimedia/player_framework/test/fuzztest/player_fuzztest/playersetvolume_fuzzer/ |
D | playersetvolume_fuzzer.cpp | 40 player_ = OHOS::Media::PlayerFactory::CreatePlayer(); in FuzzSetVolume() 41 if (player_ == nullptr) { in FuzzSetVolume() 46 player_->SetPlayerCallback(cb); in FuzzSetVolume() 51 player_->SetVideoSurface(producerSurface); in FuzzSetVolume() 52 player_->PrepareAsync(); in FuzzSetVolume() 54 player_->Play(); in FuzzSetVolume() 56 player_->SetVolume(*reinterpret_cast<float *>(data), *reinterpret_cast<float *>(data)); in FuzzSetVolume() 59 player_->Release(); in FuzzSetVolume()
|
/foundation/multimedia/histreamer/tests/st/helper/ |
D | lite_player.cpp | 60 …explicit TestPlayerImpl(std::shared_ptr<Media::PlayerInterface> player) : player_(std::move(player… in TestPlayerImpl() 80 std::shared_ptr<Media::PlayerInterface> player_; member in OHOS::Media::Test::TestPlayerImpl 95 return player_->SetSource(sourceParam); in SetSource() 100 return player_->SetLoop(loop); in SetSingleLoop() 110 return player_->Prepare(); in Prepare() 116 return player_->Play(); in Play() 121 return player_->Pause(); in Pause() 126 player_ = nullptr; in Release() 132 return player_->Stop(); in Stop() 137 return player_->Reset(); in Reset() [all …]
|
D | std_player.cpp | 41 player_ = player; in SetPlayer() 53 player_->Seek(0, PlayerSeekMode::SEEK_PREVIOUS_SYNC); in OnInfo() 66 IPlayerEngine* player_ {nullptr}; member in OHOS::Media::Test::PlayerCallbackImpl 72 explicit TestPlayerImpl(std::unique_ptr<IPlayerEngine> player) : player_(std::move(player)) {} in TestPlayerImpl() 90 std::unique_ptr<IPlayerEngine> player_; member in OHOS::Media::Test::TestPlayerImpl 118 ret = player_->SetSource(source.url_); in SetSource() 121 ret = player_->SetSource(src); in SetSource() 131 return player_->SetLooping(loop); in SetSingleLoop() 144 int32_t ret = player_->Prepare(); in Prepare() 157 int32_t ret = player_->Play(); in Play() [all …]
|
/foundation/multimedia/player_framework/test/fuzztest/player_fuzztest/playerseek_fuzzer/ |
D | playerseek_fuzzer.cpp | 40 player_ = OHOS::Media::PlayerFactory::CreatePlayer(); in FuzzSeek() 41 if (player_ == nullptr) { in FuzzSeek() 46 int32_t ret = player_->SetPlayerCallback(cb); in FuzzSeek() 54 player_->SetVideoSurface(producerSurface); in FuzzSeek() 55 player_->PrepareAsync(); in FuzzSeek() 57 player_->Play(); in FuzzSeek() 60 player_->Seek(data_, SEEK_NEXT_SYNC); in FuzzSeek() 63 player_->Release(); in FuzzSeek()
|
/foundation/multimedia/media_lite/interfaces/kits/player_lite/js/builtin/src/ |
D | audio_player.cpp | 137 AudioPlayer::AudioPlayer() : player_(nullptr), in AudioPlayer() 237 player_ = new Media::Player(); in CreatePlayer() 238 if (player_ == nullptr) { in CreatePlayer() 243 player_->SetVolume(0, 0); in CreatePlayer() 246 if (player_->SetVolume(volume, volume) != 0) { in CreatePlayer() 254 player_->SetPlayerCallback(callback_); in CreatePlayer() 260 if (player_ != nullptr) { in DestoryPlayer() 261 if (player_->IsPlaying() && player_->Stop() != 0) { in DestoryPlayer() 264 if (player_->Reset() != 0) { in DestoryPlayer() 267 if (player_->Release() != 0) { in DestoryPlayer() [all …]
|
/foundation/multimedia/media_lite/services/player_lite/server/src/ |
D | player_server.cpp | 300 int32_t ret = player_->SetSource(streamSource); in SetStreamSource() 334 if (player_ == nullptr) { in SetSource() 336 player_ = PlayerFactory::CreatePlayer(); in SetSource() 341 …if (player_ == nullptr || player_->GetPlayerState(state) != 0 || state != static_cast<int32_t> (PL… in SetSource() 352 WriteInt32(reply, player_->SetSource(sourceUri)); in SetSource() 373 if (player_ != nullptr) { in Prepare() 374 WriteInt32(reply, player_->Prepare()); in Prepare() 383 if (player_ != nullptr) { in Play() 384 WriteInt32(reply, player_->Play()); in Play() 393 if (player_ != nullptr) { in IsPlaying() [all …]
|
/foundation/multimedia/player_framework/frameworks/native/system_sound/ |
D | audio_ringtone_manager.cpp | 230 if (player_ != nullptr) { in ~RingtonePlayer() 231 player_->Release(); in ~RingtonePlayer() 232 player_ = nullptr; in ~RingtonePlayer() 239 player_ = PlayerFactory::CreatePlayer(); in InitPlayer() 240 CHECK_AND_RETURN_LOG(player_ != nullptr, "Failed to create ringtone player instance"); in InitPlayer() 245 player_->SetPlayerCallback(callback_); in InitPlayer() 253 …CHECK_AND_RETURN_RET_LOG(player_ != nullptr, MSERR_INVALID_VAL, "Ringtone player instance is null"… in PrepareRingtonePlayer() 261 (void)player_->Reset(); in PrepareRingtonePlayer() 263 auto ret = player_->SetSource(kvstoreUri); in PrepareRingtonePlayer() 269 ret = player_->SetParameter(format); in PrepareRingtonePlayer() [all …]
|
/foundation/multimedia/media_lite/services/player_lite/impl/ |
D | player_impl.cpp | 68 : player_(nullptr), speed_(1.0), playerControlState_(PLAY_STATUS_IDLE), in PlayerImpl() 132 player_ = nullptr; in ~PlayerImpl() 154 CHK_NULL_RETURN(player_); in SetSource() 245 curPlayer->player_->Pause(); in PlayerControlEventCb() 250 curPlayer->player_->Pause(); in PlayerControlEventCb() 276 CHK_NULL_RETURN(player_); in Prepare() 290 int ret = player_->RegCallback(param); in Prepare() 297 ret = player_->Prepare(); in Prepare() 304 (void)player_->SetAudioStreamType(audioStreamType_); in Prepare() 306 ret = player_->GetFileInfo(formatFileInfo_); in Prepare() [all …]
|
D | player_impl.h | 121 std::shared_ptr<PlayerControl> player_; variable
|
/foundation/multimedia/player_framework/frameworks/js/avplayer/ |
D | avplayer_napi.cpp | 128 jsPlayer->player_ = PlayerFactory::CreatePlayer(); in Constructor() 129 CHECK_AND_RETURN_RET_LOG(jsPlayer->player_ != nullptr, result, "failed to CreatePlayer"); in Constructor() 135 (void)jsPlayer->player_->SetPlayerCallback(jsPlayer->playerCb_); in Constructor() 207 int32_t ret = player_->PrepareAsync(); in PrepareTask() 285 int32_t ret = player_->Play(); in PlayTask() 361 int32_t ret = player_->Pause(); in PauseTask() 429 int32_t ret = player_->Stop(); in StopTask() 507 int32_t ret = player_->Reset(); in ResetTask() 600 if (player_ != nullptr) { in ReleaseTask() 601 (void)player_->ReleaseSync(); in ReleaseTask() [all …]
|
/foundation/arkui/ace_engine/frameworks/core/components/video/ |
D | video_element.cpp | 160 if (player_) { in ~VideoElement() 161 player_->PopListener(); in ~VideoElement() 225 player_ = videoComponent->GetPlayer().Upgrade(); in InitStatus() 228 if (player_ && texture_) { in InitStatus() 669 return player_ != nullptr; in HasPlayer() 1010 player_ = AceType::MakeRefPtr<Player>(id, src_, context_, std::move(errorCallback)); in CreatePlayer() 1011 player_->SetMute(isMute_); in CreatePlayer() 1012 player_->SetAutoPlay(isAutoPlay_); in CreatePlayer() 1014 player_->Create(nullptr); in CreatePlayer() 1090 player_->AddPreparedListener(onPrepared); in InitListener() [all …]
|
D | video_component.h | 302 player_ = player; in SetPlayer() 307 return player_; in GetPlayer() 377 WeakPtr<Player> player_; variable
|
/foundation/multimedia/player_framework/frameworks/native/player/test/unittest/include/ |
D | player_unit_test.h | 36 std::shared_ptr<PlayerMock> player_ = nullptr;
|
/foundation/multimedia/media_lite/services/player_lite/server/include/ |
D | player_server.h | 48 std::shared_ptr<PlayerInterface> player_; 53 PlayerServer() : player_(nullptr), stream_(nullptr), sid_(nullptr) {} in PlayerServer()
|
/foundation/multimedia/player_framework/test/fuzztest/common/ |
D | test_player.h | 32 std::shared_ptr<Player> player_ = nullptr; variable
|
D | test_player.cpp | 108 int32_t retValue = player_->SetSource(fdValue, offsetValue, lengthValue); in SetFdSource()
|
/foundation/multimedia/media_lite/interfaces/kits/player_lite/ |
D | player.h | 419 PlayerClient* player_; variable
|
/foundation/multimedia/media_lite/interfaces/kits/player_lite/js/builtin/include/ |
D | audio_player.h | 161 Media::Player *player_; variable
|