您当前的位置:首页 > IT编程 > C++
| C语言 | Java | VB | VC | python | Android | TensorFlow | C++ | oracle | 学术与代码 | cnn卷积神经网络 | gnn | 图像修复 | Keras | 数据集 | Neo4j | 自然语言处理 | 深度学习 | 医学CAD | 医学影像 | 超参数 | pointnet | pytorch | 异常检测 | Transformers | 情感分类 | 知识图谱 |

自学教程:C++ updateAnimations函数代码示例

51自学网 2021-06-03 09:13:16
  C++
这篇教程C++ updateAnimations函数代码示例写得很实用,希望能帮到您。

本文整理汇总了C++中updateAnimations函数的典型用法代码示例。如果您正苦于以下问题:C++ updateAnimations函数的具体用法?C++ updateAnimations怎么用?C++ updateAnimations使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。

在下文中一共展示了updateAnimations函数的16个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: RELEASE_ASSERT

void SMILTimeContainer::begin(){    RELEASE_ASSERT(!m_beginTime);    if (!handleAnimationPolicy(RestartOnceTimerIfNotPaused))        return;    double now = currentTime();    // If 'm_presetStartTime' is set, the timeline was modified via setElapsed() before the document began.    // In this case pass on 'seekToTime=true' to updateAnimations().    m_beginTime = now - m_presetStartTime;#if !ENABLE(OILPAN)    DiscardScope discardScope(m_ownerSVGElement);#endif    SMILTime earliestFireTime = updateAnimations(SMILTime(m_presetStartTime), m_presetStartTime ? true : false);    m_presetStartTime = 0;    if (m_pauseTime) {        m_pauseTime = now;        // If updateAnimations() caused new syncbase instance to be generated,        // we don't want to cancel those. Excepting that, no frame should've        // been scheduled at this point.        ASSERT(m_frameSchedulingState == Idle || m_frameSchedulingState == SynchronizeAnimations);    } else if (!hasPendingSynchronization()) {        ASSERT(isTimelineRunning());        // If the timeline is running, and there's pending animation updates,        // always perform the first update after the timeline was started using        // the wake-up mechanism.        if (earliestFireTime.isFinite()) {            SMILTime delay = earliestFireTime - elapsed();            scheduleWakeUp(std::max(initialFrameDelay, delay.value()), SynchronizeAnimations);        }    }}
开发者ID:kjthegod,项目名称:WebKit,代码行数:35,


示例2: updateAnimations

void AnimationControllerPrivate::scheduleService(){    double timeToNextService = -1;    double timeToNextEvent = -1;    updateAnimations(timeToNextService, timeToNextEvent, DoNotCallSetNeedsStyleRecalc);    scheduleService(timeToNextService, timeToNextEvent);}
开发者ID:chunywang,项目名称:blink-crosswalk,代码行数:7,


示例3: while

/** * Runs the game! WHOO! */int Game::start() {    game_running = true;    while(window.isOpen()) {        while(game_running) {            sf::Event event;            while(window.pollEvent(event)) {                if(event.type == sf::Event::Closed) {                    window.close();                    game_running = false;                    game_over = true;                }            }            bullets = p.getBullets();            spawnEnemies();            checkInput();            checkBorderCollision(p);            checkEntityCollision();            checkDeath();            updateAnimations();            updateScore();            updateInterface();            updateGameClocks();            for(std::vector<Enemy*>::iterator iter  = enemies.begin(); iter != enemies.end(); ++iter) {                Enemy *eni = *iter;                eni->stalkPlayer(p);            }            window.clear(sf::Color(0,230,0));            Sword * s = p.getSword();            if(s->isSwung()) {                window.draw(s->shape);            }                        window.draw(p.shape);            for(std::vector<Enemy*>::iterator iter  = enemies.begin(); iter != enemies.end(); ++iter) {                Enemy *eni = *iter;                window.draw(eni->shape);            }            for(std::vector<Bullet*>::iterator iter = bullets.begin(); iter != bullets.end(); ++iter) {                Bullet *b = *iter;                window.draw(b->shape);            }            for(std::vector<sf::Drawable*>::iterator iter = interface.begin(); iter != interface.end(); ++iter) {                sf::Drawable *d = *iter;                window.draw(*d);            }            window.display();        }        setupEntities();        game_running = true;    }    return 0;}
开发者ID:timothyhahn,项目名称:StopDying,代码行数:63,


示例4: updateAnimations

void AnimationControllerPrivate::animationFrameCallbackFired(){    double timeToNextService = updateAnimations(CallSetChanged);    if (timeToNextService >= 0)        m_frame.document()->view()->scheduleAnimation();}
开发者ID:CannedFish,项目名称:webkitgtk,代码行数:7,


示例5: while

void Application::go(){	Ogre::Timer loopTimer;	bool continueRunning = true;	while ( continueRunning )	{		Ogre::WindowEventUtilities::messagePump();				SimpleInputManager::capture();		// Update logic stuff		float elapsedSeconds = loopTimer.getMicroseconds() * 1.0 / 1000000;		updateLogic( elapsedSeconds );		// Update graphics stuff		updateAnimations( elapsedSeconds );				bool windowClosed = m_window->isClosed();		continueRunning &= ! windowClosed;		updateStats();		loopTimer.reset();		bool renderFrameSuccess = m_root->renderOneFrame();		continueRunning &= renderFrameSuccess;		continueRunning &= ! m_exitRequested;			}}
开发者ID:juanjmostazo,项目名称:ouan-tests,代码行数:30,


示例6: currentTime

void SMILTimeContainer::setElapsed(SMILTime time){    // If the documment didn't begin yet, record a new start time, we'll seek to once its possible.    if (!m_beginTime) {        m_presetStartTime = time.value();        return;    }    if (m_beginTime)        m_timer.stop();    double now = currentTime();    m_beginTime = now - time.value();    m_accumulatedPauseTime = 0;    if (m_pauseTime)        m_pauseTime = now;    Vector<SVGSMILElement*> toReset;    copyToVector(m_scheduledAnimations, toReset);    for (unsigned n = 0; n < toReset.size(); ++n)        toReset[n]->reset();    updateAnimations(time, true);}
开发者ID:sanyaade-webdev,项目名称:webkit,代码行数:25,


示例7: monotonicallyIncreasingTime

void SMILTimeContainer::setElapsed(SMILTime time){    // If the documment didn't begin yet, record a new start time, we'll seek to once its possible.    if (!m_beginTime) {        m_presetStartTime = time.value();        return;    }    if (m_beginTime)        m_timer.stop();    double now = monotonicallyIncreasingTime();    m_beginTime = now - time.value();    if (m_pauseTime) {        m_resumeTime = m_pauseTime = now;        m_accumulatedActiveTime = time.value();    } else        m_resumeTime = m_beginTime;#ifndef NDEBUG    m_preventScheduledAnimationsChanges = true;#endif    for (auto& it : m_scheduledAnimations) {        AnimationsVector* scheduled = it.value.get();        unsigned size = scheduled->size();        for (unsigned n = 0; n < size; n++)            scheduled->at(n)->reset();    }#ifndef NDEBUG    m_preventScheduledAnimationsChanges = false;#endif    updateAnimations(time, true);}
开发者ID:clbr,项目名称:webkitfltk,代码行数:35,


示例8: updateAnimations

//------------------------------------------- update.void ofxAssimpModelLoader::update() {    updateAnimations();    updateMeshes(scene->mRootNode, ofMatrix4x4());    if(hasAnimations() == false) {        return;    }    updateBones();    updateGLResources();}
开发者ID:krysmopompas,项目名称:OpenFrameworks-ng,代码行数:10,


示例9: updateAnimations

void AnimationControllerPrivate::scrollWasUpdated(){    auto* view = m_frame.view();    if (!view || !wantsScrollUpdates())        return;    m_scrollPosition = view->scrollOffsetForFixedPosition().height().toFloat();    // FIXME: This is updating all the animations, rather than just the ones    // that are dependent on scroll. We to go from our AnimationBase to its CompositeAnimation    // so we can execute code similar to updateAnimations.    // https://bugs.webkit.org/show_bug.cgi?id=144170    updateAnimations(CallSetChanged);}
开发者ID:cheekiatng,项目名称:webkit,代码行数:13,


示例10: QMainWindow

MainWindow::MainWindow(QWidget *parent) :    QMainWindow(parent),    ui(new Ui::MainWindow){    // Inicializace programu    actualPosition = Vector2(0,0);    ui->setupUi(this);    animationTimer = new QTimer(this);    actualPositionSet = false;    iterations = 1;    // P
C++ updateBoundingRect函数代码示例
C++ updateAnchorPoint函数代码示例
万事OK自学网:51自学网_软件自学网_CAD自学网自学excel、自学PS、自学CAD、自学C语言、自学css3实例,是一个通过网络自主学习工作技能的自学平台,网友喜欢的软件自学网站。