2
0
mirror of https://github.com/boostorg/gil.git synced 2026-01-19 04:12:11 +00:00

106 Commits

Author SHA1 Message Date
René Ferdinand Rivera Morell
8fd5cc5b32 Add support for modular build structure. (#752)
* Make the library modular usable.

* Add missing modular build.jam. And fix gitignore that caused it to be originally deleted!

* Switch to library requirements instead of source. As source puts extra source in install targets.

* Add missing import-search for cconfig/predef checks.

* Add requires-b2 check to top-level build file.

* Bump B2 require to 5.2

* Update copyright dates.

* Move inter-lib dependencies to a project variable and into the build targets.

* Update build deps.
2024-08-20 15:03:19 +02:00
Dirk Stolle
74ffdcb047 chore: fix some typos (#751) 2024-07-08 10:40:31 +02:00
Mateusz Loskot
6dc55c6bfc build: Add cxx14_constexpr requirement to example/Jamfile 2022-07-21 23:47:57 +02:00
Mateusz Loskot
f52cc35f6a chore: Tidy up 2022-07-21 23:47:35 +02:00
Mateusz Loskot
4d80bc881f build: Remove unused Boost.Build imports from example/Jamfile 2022-07-21 23:47:05 +02:00
Mateusz Łoskot
00423cca03 chore: Update CMakeSettings.json sample [ci skip] 2022-06-29 00:14:28 +02:00
Mateusz Łoskot
5c3cfc7f7b docs: Bump C++11 to C++14 as current required (#700)
Related to #677
2022-06-27 22:47:47 +02:00
Marco Langer
d5492e1ace feat: Added apply_rasterizer() free function (#695)
This PR implements the gil::apply_rasterizer()
free function mentioned in #680.
2022-06-27 09:54:58 +02:00
Marco Langer
adddbec896 refactor: Ellipse rasterizer according to the comment at (#692)
https://github.com/boostorg/gil/pull/585#issuecomment-1144412220
2022-06-26 13:33:53 +02:00
Olzhas Zhumabek
48d7ebffe0 Move diffusion and Hough transform
Move anisotropic diffusion and
Hough transform into extension.
Adjust tests and cmakelists
2022-05-31 02:37:56 +06:00
Olzhas Zhumabek
f87ee565c1 In depth explanation for Hough line
Added in depth explanation for
Hough line transform in the
associated markdown file
2022-05-31 02:37:56 +06:00
Olzhas Zhumabek
bab2a370ff Fix Hough transform and move rasterization
Hough line transform had incorrect
rounding which lead to misleading message
2022-05-31 02:37:56 +06:00
Dirk Stolle
1be8c87c10 chore: do not use deprecated header in test or elsewhere (#675) 2022-05-18 23:25:36 +02:00
Dirk Stolle
4f83beb735 style: Remove trailing space characters (#651) 2022-04-26 20:52:56 +02:00
Paul92
caf92fa94b Renamed adaptive_he to adaptive_histogram_equalization (#638) 2022-04-21 16:38:19 +02:00
Pranam Lashkari
9bd8642f69 numeric extension move into core part 5
moved numeric/kernel.hpp into core
2022-02-18 14:25:59 +05:30
Pranam Lashkari
483915cb20 numeric extension move into core part 3
moved numeric/convolve.hpp into core
2022-02-18 14:25:59 +05:30
Pranam Lashkari
2562e11241 numeric extension move into core 1
moved numeric/algorithm.hpp into core
2022-02-18 14:25:59 +05:30
Mateusz Łoskot
0accacdbe6 Fix warning: comparison of integer expressions of different signedness 2022-02-05 14:20:14 +01:00
Nicolas Herry
0b24f4cdbf Ensure all examples build without error (#628)
* Added all missing examples, dodgy Jamfile still
* Fixed attributions and Jamfile indent
* One readme per example: synopsis, build and exec reqs
* Cleaned up example/convolve2d.cpp
* Added example target to root Jamfile

Closes #436
2021-11-10 18:21:02 +01:00
meshtag
bc3a6c0db9 Add rasterizer support for ellipse (#585)
* Added all standard morphological transformations
* Should handle grayscale dilation/erosion
* Added test cases and improved code structure
* Should handle multichannel images
2021-03-28 21:00:12 +02:00
René Ferdinand Rivera Morell
f18445f90b Repoint B2 refs to new non-boostorg home. (#571) 2021-03-01 21:15:02 +01:00
meshtag
1e8526797e Added all standard morphological transformations (#541)
* Added all standard morphological transformations

* Improved comments and some other things

* Applied adviced changes

* Applied adviced changes

* Should handle grayscale dilation/erosion

* Checking

* Added test cases and improved code structure

* Added command line control

* Added command line control

* Rectified some things

* Rectified some more things

* Improved comments

* Improved comments

* Improved doxygen comments and added more test cases

* Improved compatibility for builds and rectifying whitespace use

* Minor improvement in comments

* Did clang formatting

* pushed enum class inside namespace 'detail' and some other things

* Should handle multichannel images

* Clang formatting attempt

* got rid of if/else comparators for target_element

* Adds morphology.hpp declaration in boost/gil.hpp

* Fix newline

* (std::max)(a, b) instead of std::max(a, b)

* Improved Formatting
2021-02-13 22:01:22 +06:00
Scramjet911
90f7952b05 Fixed most of warnings in examples and some in core library (#545) 2021-02-02 18:53:16 +01:00
Mateusz Łoskot
5d63cf6798 Fix more warnings in examples
Completing https://github.com/boostorg/gil/pull/545
2021-01-28 22:15:50 +01:00
Olzhas Zhumabek
a37f12b3e9 Add implementation of Hough transforms (#512)
Support construction from step_size, step_count, and a function for angles

Implement angle and radious version of Hough line transform and adds a demo
with static line that goes over secondary diagonal.

Implement incremental line raster
Implement naive line raster
Implement Bresenham line raster
Leave only Bresenham line rasterization

Naive and incremental algorithms were removed because they are supposed
to produce the same results anyway.
The reason for diverging results is inaccuracy of floating point numbers

Add circle rendering through trigonometric functions, using
arctan(1 / (radius + 1)) as minimal angle step.

Trigonometric circle rasterizer does not follow circle equation, but still
produces very round shapes.
A new testing methodology needs to be devised for this rasterizer.

The new version accepts start and points inclusively and tries to use
canonic representation during computations.

Slope decided to be is (diff_y + 1) / (diff_x + 1).
2021-01-25 23:31:39 +01:00
Debabrata Mandal
a68a95d5f4 Add code for ahe algorithm (#516) 2021-01-24 23:22:48 +01:00
Olzhas Zhumabek
b82aed8f8e Implement hstack and vstack (#506)
Allow non-equal dims along stack dim
Width can be different in hstack, height can be different in vstack
2021-01-24 21:43:06 +01:00
Debabrata Mandal
77255e9e61 Add histogram matching algorithm (#515) 2021-01-24 21:33:38 +01:00
Debabrata Mandal
fb7512c29f Add histogram equalization feature (#514)
Co-authored-by: codejaeger <dhabalm1@>
2021-01-24 21:32:39 +01:00
Debabrata Mandal
3e729e5dae Add histogram class and related functionality (#499)
A new histogram class proposed with close suport for gil
image constructs.

Shift the stl support implmentation to extension to
serve as example for overloading fill_histogram.

Add cumulative histogram and histogram normalization.

Co-authored-by: debabrata1 <debabrata@goodhealthapp.com>
2021-01-24 00:02:51 +01:00
Olzhas Zhumabek
cb5bc9d8c2 Add Perona–Malik anisotropic diffusion algorithm (#500)
The output type must be floating point, thus a check was added to make sure it
is the case. Though I had to add specific cases for float32_t as std::is_floating_point does not
consider it a floating point type

The accumulate part was wrong, it multiplied by delta_t on every sum, which is wrong

Use 8 way nabla compute.
This is just different discretization of Laplace operator
https://en.wikipedia.org/wiki/Discrete_Laplace_operator

Laplace stencils are now the same as in mathematical notation

The new function will provide a uniform way to generate stencils
by making sure directions are indexed properly

Add only required stencil points:
The 5 points Laplace stencil is now adding only required points and not assuming that others are zero
2021-01-22 23:55:17 +01:00
Mateusz Łoskot
0dc68398b8 CMakeSettings.json: Fix use of BOOST_GIL_ENABLE_EXT_NUMERIC [ci skip] 2020-07-27 02:51:02 +02:00
Mateusz Łoskot
e27454d040 CMakeSettings.json: Add 1.74 to Boost_ADDITIONAL_VERSIONS [ci skip] 2020-07-26 13:51:11 +02:00
Samuel Debionne
601790f241 Replace Boost.Variant with Boost.Variant2 (#474)
* Update documentation
* Update example
* Update io and extensions
2020-04-17 19:25:19 +02:00
Mateusz Łoskot
23702f9879 Add good-enough .clang-format to example/clang-format/
This is an example which offers _good enough_ configuration and
may be useful when writing code for GIL, not required though.

This is **not** a complete configuration!

Closes #87
2020-03-26 00:38:24 +01:00
siddhant2001
cd2c894b4c Update example/Jamfile to compile all programs with b2 (#437)
Completes one of tasks of #436
2020-03-01 21:17:59 +01:00
Mateusz Łoskot
b1811c019d Include CTest to enable BUILD_TESTING as common CMake option [ci skip] 2020-02-21 19:20:45 +01:00
Pranam Lashkari
b03b51e4f3 Corrected the namespace in example (#427)
convolution_2d was invoked using wrong namespace in `sobel_scharr.cpp`

Change missing from #397
2020-01-20 23:54:00 +01:00
Sourabh Dharpure
5bfc4211f5 Prefix CMake parameters with BOOST_ (#419) 2020-01-16 20:14:10 +01:00
Mateusz Łoskot
5f2011b23e Fix environment variables syntax in CMakeSettings.json [ci skip] 2020-01-01 22:02:40 +01:00
Mateusz Łoskot
0875e278d1 B2: Tidy up example/b2/user-config-windows-vcpkg.jam [ci skip] 2019-12-17 18:29:07 +01:00
Mateusz Łoskot
837888bef2 B2: Add example/b2/user-config-windows-vcpkg.jam [ci skip] 2019-12-17 14:14:04 +01:00
Mateusz Łoskot
21aa1d3d39 Refactor CMakeSettings.json to allow reasonable defaults [ci skip] 2019-12-13 20:30:55 +01:00
Mateusz Łoskot
0446e9df19 CMakeSettings.json: Add 1.73 to Boost_ADDITIONAL_VERSIONS [ci skip] 2019-12-13 20:13:21 +01:00
Mateusz Łoskot
60e579b84d Typo in README [ci skip] 2019-11-10 22:31:27 +01:00
Olzhas Zhumabek
62379dd5b9 Implement Sobel and Scharr operators (#392)
* Implement Sobel and Scharr operators

This commit adds Sobel and Scharr
operators with support for 0th and 1st
degrees with other degrees planned for
later

* Migrate and fix Harris example

Generate Harris entries now uses
signed image view.
The Harris corner detector example
now uses the Scharr filter generator
and convolve_2d to reduce amount
of code needed.

* Fix and migrate Hessian example

The Hessian example now uses signed
image views and uses newly added kernel
generators to compute gradients

* Fix Harris and Hessian tests

The tests broke due to migration to
signed views in algorithms, but tests
were not adjusted

* Fix Jamfile for example/sobel_scharr.cpp

* Cosmetic changes

* Commented out fail tests

* Fixed pixel16 used in image16s

In Harris and Hessian tests, unsigned
pixel values was used to construct
signed image, which was causing
appveyor to error out.

* Reenable failing targets

* Unify kernel generator interface

This commit makes all kernel
generator functions to return kernel_2d
and adapts dependant threshold
function to use the new interface

* Migrate Hessian and Harris tests

Migrate Hessian and Harris tests to new
interface for kernel generators

* Migrate Harris and Hessian examples

Harris and Hessian examples now use
new interface for kernel generation

* Migrate simple_kernels tests

simple_kernels are now using kernel_2d
interface

* Add missing return

Normalized mean generation had missing
return at the end of the function

* Adapt code to namespace move

This commit reacts to kernel_2d,
convolve_2d being moved to
namespace detail
2019-10-29 22:38:04 +06:00
Mateusz Łoskot
1007627601 Add GIL_ENABLE_EXT_DYNAMIC_IMAGE to CMakeSettings.json example [ci skip] 2019-10-28 23:10:41 +01:00
Mateusz Łoskot
8235ee645a Hide convolve_1d, convolve_2d and kernel_2 in namespace detail (#397)
* Hide convolve_1d and convolve_2d in namespace detail
* Hide kernel_2d in namespace detail.
* Tidy up naming of horizontal/vertical to y/x for kernel center.

Following @lpranam comments on planned changes to convolve_2d,
which will not be ready for Boost 1.72,
@mloskot proposed to hide the function as implementation detail,
https://lists.boost.org/boost-gil/2019/10/0316.php,
until it is ready and @stefanseefeld agreed on the proposal,
https://lists.boost.org/boost-gil/2019/10/0320.php.
2019-10-24 12:50:56 +02:00
Mateusz Łoskot
c3e1fb767a CMake: Add Boost version 1.72 to CMakeSettings.json for VS 2019-10-13 18:10:05 +02:00