Esempio n. 1
0
void NWNEngine::playIntroVideos() {
	playVideo("atarilogo");
	playVideo("biowarelogo");
	playVideo("wotclogo");
	playVideo("fge_logo_black");
	playVideo("nwnintro");
}
Esempio n. 2
0
void WitcherEngine::playIntroVideos() {
	playVideo("publisher");
	playVideo("developer");
	playVideo("engine");
	playVideo("intro");
	playVideo("title");
}
Esempio n. 3
0
void MoviesCampMenu::callbackActive(Widget &widget) {
	if (widget.getTag() == "CancelButton") {
		_returnCode = 1;
		return;
	}

	if (widget.getTag() == "NWNButton") {
		sub(*_base);
		return;
	}

	if        (widget.getTag() == "NWNXP1Button") {
		// No GUI file? Harcoded?

		// Just play them one after another for now...
		playVideo("xp1_intro");
		playVideo("xp1_chap1_chap2");
		playVideo("xp1_chap2_chap3");
		playVideo("xp1_closing");
	} else if (widget.getTag() == "NWNXP2Button") {
		// No GUI file? Harcoded?

		// Just play the intro for now...
		// (Which is the only actual video anyway, the rest is in-game cinematics)
		playVideo("xp2_intro");
	}

	updateMouse();
}
Esempio n. 4
0
void JadeEngine::playIntroVideos() {
	playVideo("black");
	playVideo("publisher");
	playVideo("bwlogo");
	playVideo("graymatr");
	playVideo("attract");
}
Esempio n. 5
0
void AGOSEngine_FeebleDemo::exitMenu() {
    for (int i = 1; i <= 20; i++)
        disableBox(i);

    enableBox(21);

    playVideo("fhypno.smk");
    playVideo("fbye1.smk", true);

    HitArea *ha;
    do {
        _lastHitArea = NULL;
        _lastHitArea3 = NULL;

        while (!shouldQuit() && _lastHitArea3 == 0) {
            delay(1);
        }

        ha = _lastHitArea;
    } while (!shouldQuit() && !(ha != NULL && ha->id == 21));

    playVideo("fbye2.smk");
    quitGame();
    delay(0);
}
Esempio n. 6
0
void WenliBackWidget::initConnect()
{
    connect(m_groupButton, SIGNAL(playVideo()), this, SIGNAL(playVideo()));
    connect(m_groupButton, SIGNAL(showSkin()), this, SIGNAL(showSkin()));
    connect(m_groupButton, SIGNAL(showMenu()), this, SIGNAL(showMenu()));
    connect(m_groupButton, SIGNAL(showMin()), this, SIGNAL(showMin()));
    connect(m_groupButton, SIGNAL(closeWidget()), this, SIGNAL(closeWidget()));
    connect(m_button, SIGNAL(buttonClicked()), this, SIGNAL(buttonClicked()));
}
Esempio n. 7
0
void Functions::endGame(Aurora::NWScript::FunctionContext &ctx) {
	_game->getModule().exit();

	const Common::UString video = ctx.getParams()[0].getString();
	if (!video.empty())
		playVideo(video);

	playVideo("credits");
}
Esempio n. 8
0
void SonicEngine::playIntroVideos() {
	// Play the two logo videos
	playVideo("bioware");
	playVideo("sega");

	// TODO: We need to support playing two videos at once. The two logo videos
	// are both on the bottom screen, but (most) other videos have a top screen
	// and bottom screen video.
}
Esempio n. 9
0
void MoviesBaseMenu::callbackActive(Widget &widget) {
	if (widget.getTag() == "CloseButton") {
		_returnCode = 1;
		return;
	}

	if      (widget.getTag() == "PreludeButton")
		playVideo("prelude");
	else if (widget.getTag() == "IntroButton")
		playVideo("prelude");
	else if (widget.getTag() == "Chpt1Button")
		playVideo("prelude_chap1");
	else if (widget.getTag() == "Chpt2Button")
		playVideo("chap1_chap2");
	else if (widget.getTag() == "Chpt3Button")
		playVideo("chap2_chap3");
	else if (widget.getTag() == "Chpt4Button")
		playVideo("chap3_chap4");
	else if (widget.getTag() == "EndButton")
		playVideo("ending");
	else if (widget.getTag() == "CreditsButton")
		playVideo("credits");

	updateMouse();
}
Esempio n. 10
0
void KotOREngine::playIntroVideos() {
	if (_platform == Aurora::kPlatformXbox) {
		playVideo("logo");
		// TODO: What the hell is (sizzle|sizzle2).xmv?
	} else {
		playVideo("leclogo");
		playVideo("biologo");

		// On Mac OS X, play the Aspyr logo
		if (_platform == Aurora::kPlatformMacOSX)
			playVideo("Aspyr_BlueDust_intro");

		playVideo("legal");
	}
}
YouTubePlaybackDialog::YouTubePlaybackDialog(const QString &resourceId, const QString &title, QWidget *parent) :
    Dialog(parent),
    m_id(resourceId),
    m_title(title),
    m_model(new YouTubeStreamModel(this)),
    m_streamSelector(new ValueSelector(tr("Video format"), this)),
    m_buttonBox(new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel, Qt::Vertical, this)),
    m_layout(new QHBoxLayout(this))
{
    setWindowTitle(tr("Play video"));
    
    m_streamSelector->setModel(m_model);
    
    m_buttonBox->button(QDialogButtonBox::Ok)->setEnabled(false);
    
    m_layout->addWidget(m_streamSelector, Qt::AlignBottom);
    m_layout->addWidget(m_buttonBox, Qt::AlignBottom);
    m_layout->setStretch(0, 1);
    
    connect(m_model, SIGNAL(statusChanged(QYouTube::StreamsRequest::Status)), this,
            SLOT(onModelStatusChanged(QYouTube::StreamsRequest::Status)));
    connect(m_streamSelector, SIGNAL(valueChanged(QVariant)), this, SLOT(onStreamChanged()));
    connect(m_buttonBox, SIGNAL(accepted()), this, SLOT(playVideo()));
    connect(m_buttonBox, SIGNAL(rejected()), this, SLOT(reject()));
}
Esempio n. 12
0
void Module::enter() {
	if (!_hasModule)
		throw Common::Exception("Module::enter(): Lacking a module?!?");

	_console->printf("Entering module \"%s\"", _ifo.getName().getString().c_str());

	try {

		loadAreas();

	} catch (Common::Exception &e) {
		e.add("Can't initialize module \"%s\"", _ifo.getName().getString().c_str());
		throw e;
	}

	float entryX, entryY, entryZ, entryDirX, entryDirY;
	_ifo.getEntryPosition(entryX, entryY, entryZ);
	_ifo.getEntryDirection(entryDirX, entryDirY);

	Common::UString startMovie = _ifo.getStartMovie();
	if (!startMovie.empty())
		playVideo(startMovie);

	_exit    = false;
	_newArea = _ifo.getEntryArea();

	CameraMan.reset();

	// Roughly head position
	CameraMan.setPosition(entryX, entryZ + 2.0, entryY);
	CameraMan.setOrientation(entryDirX, entryDirY);
	CameraMan.update();
}
Esempio n. 13
0
void GraphicsManager::renderScene() {
	Common::enforceMainThread();

	cleanupAbandoned();

	if (_frameLock.load(boost::memory_order_acquire) > 0) {
		_frameEndSignal.store(true, boost::memory_order_release);

		return;
	}

	beginScene();

	if (playVideo()) {
		endScene();
		return;
	}

	renderGUIBack();
	renderWorld();
	renderGUIFront();
	renderCursor();

	endScene();

	_frameEndSignal.store(true, boost::memory_order_release);
}
Esempio n. 14
0
void Module::enter() {
	if (!_hasModule)
		throw Common::Exception("Module::enter(): Lacking a module?!?");

	if (!_pc)
		throw Common::Exception("Module::enter(): Lacking a PC?!?");

	_pc->clearVariables();

	loadTexturePack();

	_console->printf("Entering module \"%s\" with character \"%s\"",
			_ifo.getName().getString().c_str(), _pc->getName().c_str());

	_ingameGUI->updatePartyMember(0, *_pc);

	try {

		loadTLK();
		loadHAKs();
		loadAreas();

	} catch (Common::Exception &e) {
		e.add("Can't initialize module \"%s\"", _ifo.getName().getString().c_str());
		throw e;
	}

	float entryX, entryY, entryZ, entryDirX, entryDirY;
	_ifo.getEntryPosition(entryX, entryY, entryZ);
	_ifo.getEntryDirection(entryDirX, entryDirY);

	const float entryAngle = -Common::rad2deg(atan2(entryDirX, entryDirY));

	_pc->setPosition(entryX, entryY, entryZ);
	_pc->setOrientation(0.0f, 0.0f, 1.0f, entryAngle);

	_pc->loadModel();

	runScript(kScriptModuleLoad , this, _pc);
	runScript(kScriptModuleStart, this, _pc);
	runScript(kScriptEnter      , this, _pc);

	Common::UString startMovie = _ifo.getStartMovie();
	if (!startMovie.empty())
		playVideo(startMovie);

	_newArea = _ifo.getEntryArea();

	CameraMan.reset();

	// Roughly head position
	CameraMan.setPosition(entryX, entryY, entryZ + 1.8f);
	CameraMan.setOrientation(90.0f, 0.0f, entryAngle);
	CameraMan.update();

	_running = true;
	_exit    = false;

	_ingameGUI->show();
}
Esempio n. 15
0
SysButtonGroup::SysButtonGroup(QWidget *parent)
    : QWidget(parent)
{
    QHBoxLayout *hLayout = new QHBoxLayout;
    StaticButton *playButton = new StaticButton(":/main/playvideo");
    connect(playButton, SIGNAL(buttonClicked()), this, SIGNAL(playVideo()));

    StaticButton *skinButton = new StaticButton(":/main/skin");
    connect(skinButton, SIGNAL(buttonClicked()), this, SIGNAL(showSkin()));

    StaticButton *menuButton = new StaticButton(":/main/menu");
    connect(menuButton, SIGNAL(buttonClicked()), this, SIGNAL(showMenu()));

    StaticButton *minButton = new StaticButton(":/main/sys_min");
    connect(minButton, SIGNAL(buttonClicked()), this, SIGNAL(showMin()));

    StaticButton *closeButton = new StaticButton(":/main/sys_close");
    connect(closeButton, SIGNAL(buttonClicked()), this, SIGNAL(closeWidget()));

    hLayout->addWidget(playButton);
    hLayout->addWidget(skinButton);
    hLayout->addWidget(menuButton);
    hLayout->addWidget(minButton);
    hLayout->addWidget(closeButton);
    hLayout->setContentsMargins(5, 0, 5, 0);
    hLayout->setSpacing(0);

    this->setLayout(hLayout);
}
Esempio n. 16
0
void new_video_window(char *filename)
{
#ifndef IPOD
	pz_error("No video support on the desktop.");
#else /* IPOD */

	if (full_hw_version==0)
	{
		full_hw_version = ipod_get_hw_version();
	}
	outl(1, VAR_VIDEO_ON);
	outl(0, VAR_VIDEO_MODE);
	cop_wakeup();
	init_variables();
	video_status = VIDEO_CONTROL_MODE_STARTING; 
	video_curPosition = 0;
	video_gc = pz_get_gc(1);
	GrSetGCUseBackground(video_gc, GR_FALSE);
	GrSetGCForeground(video_gc, GR_RGB(0,0,0));
//nes_window("Create win");
	video_wid = pz_new_window(0, 0, screen_info.cols, screen_info.rows, video_do_draw, video_do_keystroke);

	GrSelectEvents(video_wid, 
			GR_EVENT_MASK_KEY_DOWN| GR_EVENT_MASK_KEY_UP);
	GrMapWindow(video_wid);

	GrClearWindow(video_wid, GR_FALSE);
//nes_window("Load");
	video_status_message("Loading video...");
//nes_window("Play");	
playVideo(filename);
	outl(0, VAR_VIDEO_ON);
#endif
}
Esempio n. 17
0
void Module::enter() {
	assert(_area);

	_console->printf("Entering module \"%s\"", _ifo.getName().getString().c_str());

	Common::UString startMovie = _ifo.getStartMovie();
	if (!startMovie.empty())
		playVideo(startMovie);

	_exit = false;

	CameraMan.reset();

	float entryX, entryY, entryZ;
	_ifo.getEntryPosition(entryX, entryY, entryZ);

	// Roughly head position
	CameraMan.setPosition(entryX, entryZ + 1.8, entryY);

	float entryDirX, entryDirY;
	_ifo.getEntryDirection(entryDirX, entryDirY);

	CameraMan.setOrientation(entryDirX, entryDirY);

	_area->show();
}
Esempio n. 18
0
void Module::enter() {
	if (!_hasModule)
		throw Common::Exception("Module::enter(): Lacking a module?!?");

	if (!_pc)
		throw Common::Exception("Module::enter(): Lacking a PC?!?");

	_console->printf("Entering module \"%s\"", _name.c_str());

	Common::UString startMovie = _ifo.getStartMovie();
	if (!startMovie.empty())
		playVideo(startMovie);

	float entryX, entryY, entryZ, entryAngle;
	if (!getEntryObjectLocation(entryX, entryY, entryZ, entryAngle))
		getEntryIFOLocation(entryX, entryY, entryZ, entryAngle);

	// Roughly head position
	CameraMan.setPosition(entryX, entryY, entryZ + 1.8f);
	CameraMan.setOrientation(90.0f, 0.0f, entryAngle);
	CameraMan.update();

	enterArea();

	_running = true;
	_exit    = false;
}
Esempio n. 19
0
void MoviePlayer::play(MovieText *movieTexts, uint32 numMovieTexts, uint32 leadIn, uint32 leadOut) {
	// This happens when quitting during the "eye" cutscene.
	if (_vm->shouldQuit())
		return;

	_leadOutFrame = _decoder->getFrameCount();
	if (_leadOutFrame > 60)
		_leadOutFrame -= 60;

	_movieTexts = movieTexts;
	_numMovieTexts = numMovieTexts;
	_currentMovieText = 0;
	_leadOut = leadOut;

	if (leadIn)
		_vm->_sound->playMovieSound(leadIn, kLeadInSound);

	if (_bgSoundStream)
		_snd->playStream(Audio::Mixer::kSFXSoundType, _bgSoundHandle, _bgSoundStream);

	bool terminated = false;

	terminated = !playVideo();

	closeTextObject(_currentMovieText, NULL);

	if (terminated) {
		_snd->stopHandle(*_bgSoundHandle);
		_vm->_sound->stopMovieSounds();
		_vm->_sound->stopSpeech();
	}

	while (_snd->isSoundHandleActive(*_bgSoundHandle))
		_system->delayMillis(100);
}
Esempio n. 20
0
//--------------------------------------------------------------
void kinectGuiApp::keyPressed(int key){
    if (key == 'H') { showGui = !showGui; }
    if (key == 'F') { ofToggleFullscreen(); }
    if (key == 'S') { saveSettings(); }
    if (key == 'L') { loadSettings(); }
    if (key == 'G') { grabMask(); }
    if (key == 'p') { playVideo(); }
    if (key == 'P') { pauseVideo(); }
    //if (key == ' ') { togglePlayVideo(); }
    if (key == ' ') { showBlobs = false; showMain = false; }
    if (key == 'C') { cueNextVideo(); }
    if (key == 'N') { playNextVideo(); }
    if (key == '1') { cueVideo(0); }
    if (key == '2') { cueVideo(1); }
    if (key == '3') { cueVideo(2); }
    if (key == '4') { cueVideo(3); }
    if (key == '5') { cueVideo(4); }
    if (key == '6') { cueVideo(5); }
    if (key == '7') { cueVideo(6); }
    if (key == '8') { cueVideo(7); }
    if (key == '9') { cueVideo(8); }
    if (key == '0') { cueVideo(9); }
    else if (key == 'g') { kinect.lineColor.set(ofColor(0,230,0,32)); }
    else if (key == 'b') { kinect.lineColor.set(ofColor(0,0,200,32)); }
    else if (key == 'y') { kinect.lineColor.set(ofColor(200,200,0,32)); }
    else if (key == 'm') { showBlobs = false; showMain = true; }
}
Esempio n. 21
0
void World::update()
{
	if (_playerBase == nullptr) {
		gameOver();
	} else if (_playerTank == nullptr) {
		if (_playerLife > 0) {
			_playerLife--;
			Tank *tank = new Tank;
			tank->setPos(_spawnPos[0]);
			_playerTank = tank;
			_tankList.append(tank);
		} else {
			gameOver();
		}
	} else if (_tankList.size() < 3) {
		if (_enemyLife > 0) {
			_enemyLife--;
			Tank *tank = new Tank;
			tank->setTeam(1);
			tank->setPos(_spawnPos[_tankList.size()]);
			tank->setAngle(2);
			_tankList.append(tank);
		}
	}
	if (_isVideo) {
		playVideo();
	} else {
		moveBots();
	}
	updateTanks();
	moveBullets();
}
Esempio n. 22
0
void MoviePlayer::play() {
	if (_vm->getBitFlag(40)) {
		_vm->setBitFlag(42, false);
		startSound();
		return;
	}

	_leftButtonDown = false;
	_rightButtonDown = false;
	_skipMovie = false;

	_vm->_mixer->stopAll();

	_ticks = _vm->_system->getMillis();

	startSound();

	playVideo();
	stopVideo();

	_vm->o_killAnimate();

	if (_vm->getBitFlag(41)) {
		_vm->fillBackFromFront();
	} else {
		uint8 palette[768];
		memset(palette, 0, sizeof(palette));
		_vm->clearSurfaces();
		_vm->_system->getPaletteManager()->setPalette(palette, 0, 256);
	}

	_vm->fillBackGroundFromBack();
	_vm->_fastFadeOutFlag = true;
}
Esempio n. 23
0
void MoviePlayer::play(MovieText *movieTexts, uint32 numMovieTexts, uint32 leadIn, uint32 leadOut) {
	_leadOutFrame = _decoder->getFrameCount();
	if (_leadOutFrame > 60)
		_leadOutFrame -= 60;

	_movieTexts = movieTexts;
	_numMovieTexts = numMovieTexts;
	_currentMovieText = 0;
	_leadOut = leadOut;

	if (leadIn)
		_vm->_sound->playMovieSound(leadIn, kLeadInSound);

	bool terminated = !playVideo();

	closeTextObject(_currentMovieText, NULL, 0);

	if (terminated) {
		_vm->_sound->stopMovieSounds();
		_vm->_sound->stopSpeech();
	}

	// Need to jump back to paletted color
	if (_decoderType == kVideoDecoderPSX || _decoderType == kVideoDecoderMP2)
		initGraphics(640, 480, true);
}
Esempio n. 24
0
void MoviePlayer::play() {
	if (_bgSoundStream)
		_snd->playStream(Audio::Mixer::kSFXSoundType, _bgSoundHandle, _bgSoundStream);

	bool terminated = false;

	_textX = 0;
	_textY = 0;

	terminated = !playVideo();

	if (terminated)
		_snd->stopHandle(*_bgSoundHandle);

	_textMan->releaseText(2, false);

	_movieTexts.clear();

	while (_snd->isSoundHandleActive(*_bgSoundHandle))
		_system->delayMillis(100);

	// It's tempting to call _screen->fullRefresh() here to restore the old
	// palette. However, that causes glitches with DXA movies, where the
	// previous location would be momentarily drawn, before switching to
	// the new one. Work around this by setting the palette to black.

	byte pal[3 * 256];
	memset(pal, 0, sizeof(pal));
	_system->getPaletteManager()->setPalette(pal, 0, 256);
}
Esempio n. 25
0
void Console::cmdPlayVideo(const CommandLine &cl) {
	if (cl.args.empty()) {
		printCommandHelp(cl.cmd);
		return;
	}

	playVideo(cl.args);
}
Esempio n. 26
0
void Playlist::playIndex(const QModelIndex &videoIndex)
{
    playRow = videoIndex.row();
    emit playVideo(videoPathAt(playRow));
    emit nextVideoStatusChange(hasNext());
    emit previousVideoStatusChange(hasNext());
    emit dataChanged(firstIndex, lastIndex);
}
Esempio n. 27
0
void AGOSEngine_Feeble::runSubroutine101() {
    if ((getPlatform() == Common::kPlatformAmiga || getPlatform() == Common::kPlatformMacintosh) &&
            getGameType() == GType_FF) {
        playVideo("epic.dxa");
    }

    AGOSEngine::runSubroutine101();
}
Esempio n. 28
0
void DragonAgeEngine::run(const Common::UString &target) {
	_baseDirectory = target;

	init();
	initCursors();

	if (EventMan.quitRequested())
		return;

	status("Successfully initialized the engine");

	CursorMan.hideCursor();
	CursorMan.set();

	playVideo("dragon_age_ea_logo");
	playVideo("dragon_age_main");
	if (EventMan.quitRequested())
		return;

	CursorMan.showCursor();

	bool showFPS = ConfigMan.getBool("showfps", false);

	Graphics::Aurora::FPS *fps = 0;
	if (showFPS) {
		fps = new Graphics::Aurora::FPS(FontMan.get(Graphics::Aurora::kSystemFontMono, 13));
		fps->show();
	}

	Graphics::Aurora::Cube *cube = 0;
	try {

		cube = new Graphics::Aurora::Cube("ach_abi_accomplish_rog");

	} catch (Common::Exception &e) {
		Common::printException(e);
	}

	while (!EventMan.quitRequested()) {
		EventMan.delay(10);
	}

	delete cube;
	delete fps;
}
Esempio n. 29
0
bool VideoScene::init(){
	if (!Layer::init() ){
		return false;
	}

	playVideo();

	return true;
}
Esempio n. 30
0
bool Module::enter() {
	if (!_hasModule) {
		warning("Module::enter(): Lacking a module?!?");
		return false;
	}

	if (!_pc) {
		warning("Module::enter(): Lacking a PC?!?");
		return false;
	}

	_pc->clearVariables();

	loadTexturePack();

	_console->printf("Entering module \"%s\" with character \"%s\"",
			_ifo.getName().getString().c_str(), _pc->getName().c_str());

	_ingameGUI->updatePartyMember(0, *_pc);

	try {

		loadHAKs();
		loadAreas();

	} catch (Common::Exception &e) {
		e.add("Can't initialize module \"%s\"", _ifo.getName().getString().c_str());
		printException(e, "WARNING: ");
		return false;
	}

	runScript(kScriptModuleLoad , this, _pc);
	runScript(kScriptModuleStart, this, _pc);
	runScript(kScriptEnter      , this, _pc);

	Common::UString startMovie = _ifo.getStartMovie();
	if (!startMovie.empty())
		playVideo(startMovie);

	_exit    = false;
	_newArea = _ifo.getEntryArea();

	CameraMan.reset();

	float entryX, entryY, entryZ;
	_ifo.getEntryPosition(entryX, entryY, entryZ);

	// Roughly head position
	CameraMan.setPosition(entryX, entryZ + 2.0, entryY);

	float entryDirX, entryDirY;
	_ifo.getEntryDirection(entryDirX, entryDirY);

	CameraMan.setOrientation(entryDirX, entryDirY);

	return true;
}