Implement Poisson blending algorithm in a simple photo editor with Qt Frame on Windows.
Click to open dest img, then click to open src img | |
---|---|
Click to circle an area on src img, then click to paste the circled area onto dst img | |
Click to blend the pasted area into dst img |
git clone https://github.com/MuGeminorum/QPoisson.git
cd QPoisson
Please refer to this blog post for this section.
Eigen is a C++ library for linear algebra: matrices, vectors, numerical solvers, and related algorithms.
The core method for the blending process comes from Poisson Image Editing, in which the formula of computing vector b is as follow:
b[i] = div ( G( Source(x,y) ) ) - Neighbor(target i) ; // i=1..N
Flat icon set is from easyicon; All source codes are licensed under MIT License. If you want to make any modification on these source codes while keeping new codes unprotected by MIT License, please contact me for a sublicense instead.