diff options
Diffstat (limited to 'src/feature.cpp')
-rw-r--r-- | src/feature.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/feature.cpp b/src/feature.cpp index fbb1376..84575d1 100644 --- a/src/feature.cpp +++ b/src/feature.cpp @@ -36,6 +36,7 @@ Feature::Feature ( int id, const Vector3d &xs, const Vector3d &xr, xb0w = xbw; q0 = q; _patch = p; + lastseen = 0; } /* ----- end of method Feature::Feature (constructor) ----- */ /* @@ -61,6 +62,7 @@ Feature::Feature ( int id, const Vector3d &xs, const Vector3d &xbw, xb0w = xbw; q0 = q; _patch = p; + lastseen = 0; } @@ -1023,6 +1025,7 @@ Feature::sane ( ) void Feature::dx ( const Vector3d &del ) { + lastseen += 1; X += del; return ; } /* ----- end of method Feature::dx ----- */ @@ -1131,3 +1134,16 @@ Feature::reflectedPatch( const Camera &cam, const Quaterniond &q1 ) return cam.reflectPatch(_patch, q0, q1); } +void +Feature::seen ( ) +{ + lastseen = 0; + return ; +} /* ----- end of method Feature::seen ----- */ + +bool +Feature::since ( int N ) const +{ + return (lastseen<N) ; +} /* ----- end of method Feature::since ----- */ + |