Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Frank Dana <ferdnyc@gmail.com>
  • Loading branch information
BrennoCaldato and ferdnyc committed Jan 12, 2021
1 parent 49097ce commit e19c931
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 8 deletions.
8 changes: 4 additions & 4 deletions src/effects/Stabilizer.h
Expand Up @@ -95,9 +95,9 @@ namespace openshot
Keyframe zoom;

public:
std::string teste;
std::map <size_t,EffectCamTrajectory> trajectoryData; // Save camera trajectory data
std::map <size_t,EffectTransformParam> transformationData; // Save transormation data
std::string teste;
std::map <size_t,EffectCamTrajectory> trajectoryData; // Save camera trajectory data
std::map <size_t,EffectTransformParam> transformationData; // Save transormation data

/// Blank constructor, useful when using Json to load the effect properties
Stabilizer(std::string clipTrackerDataPath);
Expand All @@ -119,7 +119,7 @@ namespace openshot
std::shared_ptr<openshot::Frame> GetFrame(int64_t frame_number) override { return GetFrame(std::shared_ptr<Frame> (new Frame()), frame_number); }

// Load protobuf data file
bool LoadStabilizedData(std::string inputFilePath);
bool LoadStabilizedData(std::string inputFilePath);

/// Get and Set JSON methods
std::string Json() const override; ///< Generate JSON string of this object
Expand Down
6 changes: 3 additions & 3 deletions src/effects/Tracker.h
Expand Up @@ -92,7 +92,7 @@ namespace openshot

public:

std::map<int, EffectFrameData> trackedDataById; // Save object tracking box data
std::map<int, EffectFrameData> trackedDataById; // Save object tracking box data

/// Blank constructor, useful when using Json to load the effect properties
Tracker(std::string clipTrackerDataPath);
Expand All @@ -113,10 +113,10 @@ namespace openshot
std::shared_ptr<openshot::Frame> GetFrame(int64_t frame_number) override { return GetFrame(std::shared_ptr<Frame> (new Frame()), frame_number); }

// Load protobuf data file
bool LoadTrackedData(std::string inputFilePath);
bool LoadTrackedData(std::string inputFilePath);

// Get tracker info for the desired frame
EffectFrameData GetTrackedData(size_t frameId);
EffectFrameData GetTrackedData(size_t frameId);

/// Get and Set JSON methods
std::string Json() const override; ///< Generate JSON string of this object
Expand Down
3 changes: 2 additions & 1 deletion src/sort_filter/KalmanTracker.cpp
Expand Up @@ -19,7 +19,8 @@ void KalmanTracker::init_kf(

measurement = Mat::zeros(measureNum, 1, CV_32F);

kf.transitionMatrix = (Mat_<float>(stateNum, stateNum) << 1, 0, 0, 0, 1, 0, 0,
kf.transitionMatrix = (Mat_<float>(7, 7) << 1, 0, 0, 0, 1, 0, 0,

0, 1, 0, 0, 0, 1, 0,
0, 0, 1, 0, 0, 0, 1,
0, 0, 0, 1, 0, 0, 0,
Expand Down

0 comments on commit e19c931

Please sign in to comment.