XMLWordPrintable

Details

    Description

      auto slide = presentation.newObject<Q3DSSlide>("slideN");
      masterSlide->appendChildNode(slide);
      // associate objects with slides
      slide1->addObject(wonderfulCarModel);
      slide1->addObject(wonderfulCarSubMesh1Material);
      ...
      // specify property changes that are to be applied when entering the slide
      slide1->addPropertyChanges(wonderfulCarModel, new Q3DSPropertyChangeList {
          Q3DSPropertyChange::fromVariant(QLatin1String("rotation"), QVector3D(0, 180, 0))
      });
      // manage animation tracks
      Q3DSAnimationTrack anim(Q3DSAnimationTrack::Linear, model1, QLatin1String("rotation.z"));
      anim.setKeyFrames({ { 0, 0 }, { 10, 360 } }); // z rotation is 0 at 0 s, 360 at 10 s
      slide2->addAnimation(anim);
      

      All these are observable via a familiar callback mechanism, so scenemanager & co will be happy as well:

          id = slide1->addSlideObjectChangeObserver([...](Q3DSSlide *slide, const Q3DSSlide::SlideObjectChange &change) { ... });
      

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            lagocs Laszlo Agocs
            lagocs Laszlo Agocs
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes