help wantedquestion
Repository metrics
- Stars
- (6,985 stars)
- PR merge metrics
- (No merged PRs in 30d)
Description
Hey guys , First thanks for this Amazing library, Great work , It helped me a lot. I am stuck at this problem though. I am facing difficulties in writing this code of C into Java.
StabilizerBase *stabilizer = 0;
string inputPath = "";
if (inputPath.empty())
throw runtime_error("specify video file path");
Ptr<VideoFileSource> source = makePtr<VideoFileSource>(inputPath);
cout << "frame count (rough): " << source->count() << endl;
outputFps = source->fps();
// prepare motion estimation builders
Ptr<IMotionEstimatorBuilder> motionEstBuilder;
motionEstBuilder.reset(new MotionEstimatorRansacL2Builder(false));
Ptr<IMotionEstimatorBuilder> wsMotionEstBuilder;
wsMotionEstBuilder.reset(new MotionEstimatorRansacL2Builder(false, "ws-"));
TwoPassStabilizer *twoPassStabilizer = new TwoPassStabilizer();
stabilizer = twoPassStabilizer;
twoPassStabilizer->setEstimateTrimRatio(true);
twoPassStabilizer->setMotionStabilizer(makePtr<GaussianMotionFilter>(15));
stabilizer->setFrameSource(source);
stabilizer->setMotionEstimator(motionEstBuilder->build());
stabilizedFrames.reset(dynamic_cast<IFrameSource*>(stabilizer));
MotionModel model = stabilizer->motionEstimator()->motionModel();
stabilizer->setRadius(15);
stabilizer->setTrimRatio(0.1);
stabilizer->setCorrectionForInclusion(false);
stabilizer->setBorderMode(BORDER_REPLICATE);
InpaintingPipeline *inpainters = new InpaintingPipeline();
Ptr<InpainterBase> inpainters_(inpainters);
outputPath = "";
__android_log_write(ANDROID_LOG_ERROR, "Tag", "Output path set ");
quietMode = 0;
Can anyone Help ?