Seems that the OpenCV libraries are doing a lot of stuff...
Some days ago I started to write a simple stretch function to be used as an external program for the Faststone Viewer to correct the perspective of photos. It uses the magick library (parameter -distort Perspective) for now but the lib is very large for this tiny stuff...
...can you tell me how to do a simple stretch for calculating a trapezium to a rectangle (or vice versa)?
Deform Image: MLS
- Michael Vogel
- Addict
- Posts: 2677
- Joined: Thu Feb 09, 2006 11:27 pm
- Contact:
Re: Deform Image: MLS
Hi Michael Vogel,
See my reply to your question in the following OpenCV post: viewtopic.php?p=534612#p534612
-------------------------------------------------
Updated:
- selectable Border Color
- added support for single channel images
- some minor code improvements
- squashed a couple bugs
Border Color
Only accessible from the shortcut [ B ] Key.
NB*: Currently transparency is ignored, but should be included in the next release.
See my reply to your question in the following OpenCV post: viewtopic.php?p=534612#p534612
-------------------------------------------------
Updated:
- selectable Border Color
- added support for single channel images
- some minor code improvements
- squashed a couple bugs
Border Color
Only accessible from the shortcut [ B ] Key.
NB*: Currently transparency is ignored, but should be included in the next release.
Last edited by JHPJHP on Sun Apr 07, 2019 5:18 am, edited 1 time in total.
Re: Deform Image: MLS
Updated:
- added four channel support for transparent images
- numerous minor improvements
NOTE:
The transparent background of a deformed PNG image can be changed to a solid color when the border color is changed from transparent and outputted to an animated GIF.
- Border Color defaults to transparent for PNG images and black for any other image type
Transparent Images
Using an FFmpeg Complex Filter I was able to output a transparent animated GIF, but using this method I was not able to modify the Disposal Method.
Not finding any documentation on the subject, I joined the FFmpeg Forum. After a few days without my question being answered, I wrote my own patch.
NB*: A version of the patch can be found in my GIF Toolkit download.
-----------------------------------------------------------------------
Updated:
- image sizes configured to use the built-in PureBasic DPI compiler option
- added four channel support for transparent images
- numerous minor improvements
NOTE:
The transparent background of a deformed PNG image can be changed to a solid color when the border color is changed from transparent and outputted to an animated GIF.
- Border Color defaults to transparent for PNG images and black for any other image type
Transparent Images
Using an FFmpeg Complex Filter I was able to output a transparent animated GIF, but using this method I was not able to modify the Disposal Method.
Not finding any documentation on the subject, I joined the FFmpeg Forum. After a few days without my question being answered, I wrote my own patch.
NB*: A version of the patch can be found in my GIF Toolkit download.
-----------------------------------------------------------------------
Updated:
- image sizes configured to use the built-in PureBasic DPI compiler option
Re: Deform Image: MLS
Updated:
- some minor improvements to Output Animated GIF
- some minor improvements to Output Animated GIF