Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 3851 in orxonox.OLD for orxonox/trunk/src/simple_animation.cc


Ignore:
Timestamp:
Apr 17, 2005, 1:21:59 PM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: animation: more adaptions to the new Framework

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/simple_animation.cc

    r3850 r3851  
    11
    2 
    3 
    4 /*
     2/*
    53   orxonox - the future of 3D-vertical-scrollers
    64
     
    1412   ### File Specific:
    1513   main-programmer: Patrick Boenzli
    16    co-programmer: ...
     14   co-programmer: Benjamin Grauer
     15
     16   2005-04-17: Benjamin Grauer
     17          Rewritte all functions, so it will fit into the Animation-class
    1718*/
    1819
    1920
    2021#include "simple_animation.h"
    21 #include "stdincl.h"
    22 #include "vector.h"
    23 #include "world_entity.h"
    24 
    25 using namespace std;
    26 
    27 
    28 Animation3D::Animation3D(void)
    29 {
    30 
    31 }
    32 
    33 Animation3D::~Animation3D(void)
    34 {
    35 
    36 }
    37 
    38 
    39 void Animation3D::rewind(void)
    40 {
    41 
    42 }
    43 
    44 void Animation3D::setAnimFunc(ANIM_FUNCTION animFunc)
    45 {
    46   switch (animFunc)
    47     {
    48     default:
    49     case ANIM_CONSTANT:
    50       this->animFunc = &Animation3D::constant;
    51       break;
    52     case ANIM_LINEAR:
    53       this->animFunc = &Animation3D::linear;
    54       break;
    55     case ANIM_SINE:
    56       this->animFunc = &Animation3D::sine;
    57       break;
    58     case ANIM_COSINE:
    59       this->animFunc = &Animation3D::cosine;
    60       break;
    61     case ANIM_EXP:
    62       this->animFunc = &Animation3D::exp;
    63       break;
    64     case ANIM_NEG_EXP:
    65       this->animFunc = &Animation3D::negExp;
    66       break;
    67     case ANIM_QUADRATIC:
    68       this->animFunc = &Animation3D::quadratic;
    69       break;
    70     case ANIM_RANDOM:
    71       this->animFunc = &Animation3D::random;
    72       break;
    73     }
    74 }
    75 
    76 
    77 void Animation3D::tick(float timePassed)
    78 {
    79 
    80 }
    81 
    82 
    83 float Animation3D::constant(float timePassed) const
    84 {
    85 
    86 }
    87 
    88 float Animation3D::linear(float timePassed) const
    89 {
    90 
    91 }
    92 
    93 float Animation3D::sine(float timePassed) const
    94 {
    95 
    96 }
    97 
    98 float Animation3D::cosine(float timePassed) const
    99 {
    100 
    101 }
    102 
    103 float Animation3D::exp(float timePassed) const
    104 {
    105 
    106 }
    107 
    108 float Animation3D::negExp(float timePassed) const
    109 {
    110 
    111 }
    112 
    113 float Animation3D::quadratic(float timePassed) const
    114 {
    115 
    116 }
    117 
    118 float Animation3D::random(float timePassed) const
    119 {
    120 
    121 }
    122 
    123 
    124 
    125 
    12622
    12723
     
    216112   \param object wo work on
    217113*/
    218 void SimpleAnimation::selectObject(WorldEntity* entity)
    219 {
    220   Animation3D* anim = getAnimationFromWorldEntity(entity);
     114void SimpleAnimation::selectObject(PNode* entity)
     115{
     116  Animation3D* anim = getAnimationFromPNode(entity);
    221117  if( anim == NULL)
    222118    {
     
    482378
    483379
    484 Animation3D* SimpleAnimation::getAnimationFromWorldEntity(WorldEntity* entity)
     380Animation3D* SimpleAnimation::getAnimationFromPNode(PNode* entity)
    485381{
    486382  tIterator<Animation3D>* iterator = this->animators->getIterator();
Note: See TracChangeset for help on using the changeset viewer.