mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-31 09:21:18 +02:00
Revert "gui/movieplayer.cpp: dynamic allocate/lock demux for playback"
This reverts commit 38c2f6408a
.
This commit is contained in:
@@ -84,13 +84,11 @@ CMoviePlayerGui::CMoviePlayerGui()
|
|||||||
|
|
||||||
CMoviePlayerGui::~CMoviePlayerGui()
|
CMoviePlayerGui::~CMoviePlayerGui()
|
||||||
{
|
{
|
||||||
#if 0
|
|
||||||
playback->Close();
|
playback->Close();
|
||||||
delete playback;
|
|
||||||
#endif
|
|
||||||
delete moviebrowser;
|
delete moviebrowser;
|
||||||
delete filebrowser;
|
delete filebrowser;
|
||||||
delete bookmarkmanager;
|
delete bookmarkmanager;
|
||||||
|
delete playback;
|
||||||
instance_mp = NULL;
|
instance_mp = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -100,9 +98,7 @@ void CMoviePlayerGui::Init(void)
|
|||||||
|
|
||||||
frameBuffer = CFrameBuffer::getInstance();
|
frameBuffer = CFrameBuffer::getInstance();
|
||||||
|
|
||||||
#if 0
|
|
||||||
playback = new cPlayback(3);
|
playback = new cPlayback(3);
|
||||||
#endif
|
|
||||||
moviebrowser = new CMovieBrowser();
|
moviebrowser = new CMovieBrowser();
|
||||||
bookmarkmanager = new CBookmarkManager();
|
bookmarkmanager = new CBookmarkManager();
|
||||||
|
|
||||||
@@ -410,7 +406,6 @@ void CMoviePlayerGui::PlayFile(void)
|
|||||||
{
|
{
|
||||||
neutrino_msg_t msg;
|
neutrino_msg_t msg;
|
||||||
neutrino_msg_data_t data;
|
neutrino_msg_data_t data;
|
||||||
bool post_msg = false;
|
|
||||||
menu_ret = menu_return::RETURN_REPAINT;
|
menu_ret = menu_return::RETURN_REPAINT;
|
||||||
|
|
||||||
int position = 0, duration = 0;
|
int position = 0, duration = 0;
|
||||||
@@ -425,14 +420,7 @@ void CMoviePlayerGui::PlayFile(void)
|
|||||||
printf("Startplay at %d seconds\n", startposition/1000);
|
printf("Startplay at %d seconds\n", startposition/1000);
|
||||||
handleMovieBrowser(CRCInput::RC_nokey, position);
|
handleMovieBrowser(CRCInput::RC_nokey, position);
|
||||||
|
|
||||||
int dnum = CFEManager::getInstance()->getDemux(0);
|
|
||||||
printf("CMoviePlayerGui::PlayFile: playback demux: %d\n", dnum);
|
|
||||||
if (!dnum) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
CFEManager::getInstance()->lockDemux(dnum, 0);
|
|
||||||
cutNeutrino();
|
cutNeutrino();
|
||||||
playback = new cPlayback(dnum);
|
|
||||||
playback->Open(is_file_player ? PLAYMODE_FILE : PLAYMODE_TS);
|
playback->Open(is_file_player ? PLAYMODE_FILE : PLAYMODE_TS);
|
||||||
|
|
||||||
printf("IS FILE PLAYER: %s\n", is_file_player ? "true": "false" );
|
printf("IS FILE PLAYER: %s\n", is_file_player ? "true": "false" );
|
||||||
@@ -661,14 +649,8 @@ void CMoviePlayerGui::PlayFile(void)
|
|||||||
sc->EnableVideo(true);
|
sc->EnableVideo(true);
|
||||||
sc->Start();
|
sc->Start();
|
||||||
|
|
||||||
} else if ( msg == NeutrinoMessages::RECORD_START) {
|
} else if ( msg == NeutrinoMessages::ANNOUNCE_RECORD ||
|
||||||
CTimerd::RecordingInfo * info = (CTimerd::RecordingInfo *) data;
|
msg == NeutrinoMessages::RECORD_START) {
|
||||||
CZapitChannel * channel = CServiceManager::getInstance()->FindChannel(info->channel_id);
|
|
||||||
if (channel && (CFEManager::getInstance()->getDemux(channel->getTransponderId() == 0))) {
|
|
||||||
playstate = CMoviePlayerGui::STOPPED;
|
|
||||||
post_msg = true;
|
|
||||||
}
|
|
||||||
} else if ( msg == NeutrinoMessages::ANNOUNCE_RECORD) {
|
|
||||||
CNeutrinoApp::getInstance()->handleMsg(msg, data);
|
CNeutrinoApp::getInstance()->handleMsg(msg, data);
|
||||||
} else if ( msg == NeutrinoMessages::ZAPTO ||
|
} else if ( msg == NeutrinoMessages::ZAPTO ||
|
||||||
msg == NeutrinoMessages::STANDBY_ON ||
|
msg == NeutrinoMessages::STANDBY_ON ||
|
||||||
@@ -706,10 +688,6 @@ void CMoviePlayerGui::PlayFile(void)
|
|||||||
|
|
||||||
playback->SetSpeed(1);
|
playback->SetSpeed(1);
|
||||||
playback->Close();
|
playback->Close();
|
||||||
delete playback;
|
|
||||||
CFEManager::getInstance()->unlockDemux(dnum);
|
|
||||||
if (post_msg)
|
|
||||||
g_RCInput->postMsg(msg, data);
|
|
||||||
|
|
||||||
CVFD::getInstance()->ShowIcon(FP_ICON_PLAY, false);
|
CVFD::getInstance()->ShowIcon(FP_ICON_PLAY, false);
|
||||||
CVFD::getInstance()->ShowIcon(FP_ICON_PAUSE, false);
|
CVFD::getInstance()->ShowIcon(FP_ICON_PAUSE, false);
|
||||||
|
Reference in New Issue
Block a user