Commit Graph

144 Commits

Author SHA1 Message Date
John Cupitt 4a59fa652c make vips_sobel()
cut out of vips_canny()
2018-02-26 18:33:20 +00:00
John Cupitt bc6fa2452b layout tweak 2017-12-07 08:00:19 +00:00
Lovell Fuller f0949fbfcb Allow -DDEBUG build to compile 2017-12-06 22:04:11 +00:00
John Cupitt f9f717a843 add VIPS_ONCE and use it everywhere
Lovell's idea: save the function call in the most common case
2017-11-23 08:43:08 +00:00
John Cupitt 99f02aeff1 allow approx gaussmat
works with gaussblur now
2017-10-16 17:10:16 +01:00
John Cupitt 9e0ff87dd5 add docs for autofit_dpi 2017-10-10 13:10:17 +01:00
John Cupitt 40f20e5e0a Merge branch 'master' into gargsms-text-autofit 2017-10-10 13:04:31 +01:00
Alistair Thomas 103452c3ee Correct typo in comment for out parameter of inverlut() and remove some trailing whitespace 2017-10-02 21:28:46 +01:00
Alistair Thomas 0563330b43 Update GObject introspection annotations for libvips/create directory 2017-09-30 20:47:39 +01:00
John Cupitt 393e2cd766 typo 2017-09-21 10:58:30 +01:00
John Cupitt 18d25cfa08 add autofit_dpi output property 2017-09-21 10:46:17 +01:00
John Cupitt 809f523274 text autosize could overflow 2017-09-21 10:39:37 +01:00
John Cupitt 64be1d89b5 add gravity 2017-09-20 00:43:17 +01:00
John Cupitt e07a1d83fb fix up autofit again
A bit cleaner and simpler now, stops earlier if it can.

I experimented with other ways of picking the next guess, but none were
significantly better than picking the half-way point. The problem is
that autosize can be very non-linear. Line breaks appear and disappear
as you adjust DPI and it's possible to construct cases where it never
tries the correct solution.
2017-09-19 23:02:26 +01:00
John Cupitt 06533d2c9e oop, proportion wrong 2017-09-19 13:01:12 +01:00
John Cupitt f4151d6e5b faster, more accurate convergence for autofit
better next guess, better final choice
2017-09-19 12:56:42 +01:00
John Cupitt 3cd0d5f161 try changing dpi instead of font size 2017-09-18 23:01:38 +01:00
gargsms 3a93f2b2c2 Do not change font size if the font size is already specified 2017-09-18 18:45:28 +05:30
gargsms a3955c6c0a Fix code convention, issues with gravity 2017-09-18 18:34:50 +05:30
gargsms 7aacf26bcb Fix autofit for good 2017-09-15 17:48:55 +05:30
gargsms 8f660ab45b [WIP] Autofit text in the requested dimensions 2017-08-01 23:26:24 +05:30
John Cupitt 5a26b8fc45 fix caching of vips_text()
it was never cached argh because the g_object_set() to set the default
value of an input param in _build changed the hah
2017-05-29 12:38:38 +01:00
John Cupitt 36761bcfd7 make vips_gaussnoise() pixels reproducible
previously, pixel values were regenerated on every calculation, so they
changed on recomputation

pixel values are now generated from the pixel (x, y) coordinate plus a per-call
seed

thanks MvGulik, see

https://github.com/jcupitt/nip2/issues/60

https://github.com/jcupitt/libvips/issues/583
2017-01-24 09:36:25 +00:00
John Cupitt d4d41eef6a doc improvement
see https://github.com/jcupitt/libvips/issues/521
2016-09-12 11:15:56 +01:00
John Cupitt 271d8656e9 use round() rather than rint() where appropriate
rint() rounds to nearest even, rather than nearest ... in some cases,
like geometry transforms, we want strict nearest
2016-08-20 12:59:41 +01:00
John Cupitt 88252e6794 float output from worley
no need to int it
2016-08-11 21:51:58 +01:00
John Cupitt 394fbce999 fix docs for vips_text()
oops, it's align, not alignment argh

thanks gargsms
2016-07-27 23:02:28 +01:00
John Cupitt 54aea13a8c type comments for vips_text() 2016-07-27 17:43:28 +01:00
John Cupitt 2dc43198e4 final fixups 2016-07-24 14:47:22 +01:00
John Cupitt 6db9a2fdf9 better smoothing for perlin 2016-07-24 12:58:45 +01:00
John Cupitt c469bb3983 perlin sort-of works 2016-07-24 11:46:42 +01:00
John Cupitt 99766dbd83 better hash for worley 2016-07-19 12:29:36 +01:00
John Cupitt e14c97359a done!
perlin next I guess
2016-07-19 11:53:56 +01:00
John Cupitt dac671439c kind-of working 2016-07-19 10:57:21 +01:00
John Cupitt de981cd9ec docs tweak 2016-07-08 12:18:07 +01:00
John Cupitt 0f2d1a6b0b improve docs 2016-07-08 09:15:56 +01:00
John Cupitt 1ae92bb15f make optional args into bullets
make docs easier to read
2016-05-02 10:12:37 +01:00
John Cupitt 2ca7b29214 better gauss mat generation 2016-03-10 22:01:55 +00:00
John Cupitt d351e07a6b finish up 2016-03-10 17:33:34 +00:00
John Cupitt 2698688c94 oops spelling 2016-01-26 13:37:56 +00:00
John Cupitt 4d18300560 add VIPS_FABS/MAX/MIN/CLIP
macros which use the gcc __builtin_fabs() etc. functions when they can
2016-01-26 12:26:21 +00:00
John Cupitt 1504ca7cdc have a more formal max image dimension
we now have VIPS_MAX_COORD for maximum image dimension, set to 10m
pixels ... we could go up to 2bn, but 10m seems a reasonable max, at
least for now

see https://github.com/jcupitt/libvips/issues/355
2015-12-03 12:14:39 +00:00
John Cupitt 956e2f5cdf tiny cleanups
see https://github.com/jcupitt/libvips/pull/327

- small layout changes
- rename @linespacing as @spacing
- add ChangeLog notes and gtk-doc notes
- fix text arg priority
2015-09-20 11:08:44 +01:00
Lei Yang 13fad7a264 create/text: adding linespacing support 2015-09-18 22:01:18 +08:00
John Cupitt 8c5ef3812e oops, fabs()/abs() mixup 2015-05-31 18:10:34 +01:00
John Cupitt 59b47f3900 better compt for old vips_gaussmat() code 2014-12-17 10:36:14 +00:00
John Cupitt 6e2135d8b5 mask builders take prec, not integer
vips_gaussmat() and vips_logmat() used to default to float, but
vips_conv() defaulted to int ... so this failed:

	vips gaussmat m.v 2 0.1 --separable
	vips convsep k2.jpg x.jpg m.v

since we were using a small float mask with an integer convolution

This change makes everything int by default, with gaussmat having a new
param called --precision whose arg can be int or float.

The old @integer param is deprecated.
2014-12-16 20:48:11 +00:00
John Cupitt 384a5e05dc change parameters of vips_gaussblur()
sorry :-(

The old param (passing sigma*2 as an int) were just too confusing
coming from other packages. This new behaviour matches ImageMagick, and
almost everyone else in the world.

A new optional param lets you set the minimum amplitude as well.
2014-11-19 12:27:26 +00:00
John Cupitt 394149e9e8 fix all docs warnings 2014-11-17 10:32:40 +00:00
John Cupitt ccedc7c037 better random numbers for gaussnoise
fixes a problem with repeated use of gaussnoise
2014-11-08 19:37:18 +00:00
John Cupitt be4ffa6d8a more pyvips8 docs
and cleanups of various small doc markup errors
2014-11-07 14:49:18 +00:00
John Cupitt 02e8c600db more small docs work
and don't cache gaussnoise
2014-11-07 09:25:40 +00:00
John Cupitt ce8d7e5789 tweaks 2014-09-13 18:03:25 +01:00
John Cupitt 8a1397b91f small python fixes 2014-09-13 17:24:59 +01:00
John Cupitt 7ca9121c32 gtk-doc fixes 2014-09-06 08:01:13 +01:00
John Cupitt 6f8b5c6745 bring the rest of the API into python 2014-09-05 23:18:16 +01:00
John Cupitt 7608524f61 fix up gtk-doc comments
fewer warnings now, phew
2014-09-03 14:32:55 +01:00
John Cupitt fe7bd9bdcc add vips_resize()
a wrapper over affine that just scales ... much faster from the
command-line, since it can set SEQ mode
2014-08-13 13:57:52 +01:00
John Cupitt 0bb8a218bb exit() in fewer cases
we now only exit() when we know the stack has been trashed, just warn in
other cases
2014-07-29 15:23:27 +01:00
John Cupitt cdecee2705 more vips7 compat fixes
thanks steve
2014-07-16 09:40:26 +01:00
John Cupitt 235eb87aa5 sort out sense of fourier filter masks 2014-07-15 09:05:00 +01:00
John Cupitt df225a97ff small fixes 2014-03-17 13:56:55 +00:00
John Cupitt ffed43dffe add basic auto-rotate support to vipsthumbnail 2014-03-06 19:39:18 +00:00
John Cupitt 62307d18ef fix to vips_grey() --uchar 2014-03-06 13:56:12 +00:00
John Cupitt e489d2e099 add --uchar option to vips_linear() 2014-01-14 19:31:19 +00:00
John Cupitt 2a81c611c5 Merge remote-tracking branch 'origin/7.36'
Conflicts:
	ChangeLog
	configure.ac
	libvips/deprecated/im_exr2vips.c
	libvips/foreign/radiance.c
2014-01-09 14:30:52 +00:00
John Cupitt 2c184ac06a redo im_fractsurf() as a class 2014-01-04 14:38:30 +00:00
John Cupitt 1f51409bf1 remove old vips7 mask stuff
just a wrapper now
2014-01-03 14:24:04 +00:00
John Cupitt bd17e1811b oops forgot the fractal filter 2014-01-03 12:58:48 +00:00
John Cupitt 2fbaf2d051 finish new mask funcs
revised docs too
2014-01-03 12:40:13 +00:00
John Cupitt 54b6ef4e87 rename ffilter as mask
ffilter was annoying to type
2014-01-03 09:55:21 +00:00
John Cupitt dde6e4508a rewrite (most of) the freq mask builders
all classes now, except gauss band filter
2014-01-02 18:29:59 +00:00
John Cupitt e8c4188936 be more forgiving about x values
buildlut() would fail if rounding moved some of your x values away from
ints
2013-12-10 14:56:14 +00:00
John Cupitt 12cf71a6a9 combin copy_fields and demand_hint
We had two API calls, vips_image_copy_fields() and vips_demand_hint().
They are now combined in the single vips_image_pipeline() call.

All operations are now slightly smaller and simpler.
2013-10-22 09:29:40 +01:00
John Cupitt 7ef4573f18 redo im_log_*mask() as classes 2013-10-20 16:10:22 +01:00
John Cupitt 4e06d0a2b4 redo im_gauss*mask*() as classes 2013-10-20 12:17:29 +01:00
John Cupitt 0fcff235b3 deprecate im_tone_map() and im_tone_analyze()
too trivial and specialised to be worth redoing
2013-10-02 10:36:00 +01:00
John Cupitt d029461bc0 redo im_tone_build*() as classes
start vips_hist_percent() as well
2013-09-20 14:33:34 +01:00
John Cupitt 4e8f25bd4e invertlut fix 2013-09-17 21:54:28 +01:00
John Cupitt 7a5e04ba00 redo im_invertlut() as a class 2013-09-05 09:11:23 +01:00
John Cupitt 222a7abdbf start on vips_invertlut() 2013-09-04 14:58:07 +01:00
John Cupitt 0180a61be4 move im_identity*() to a class 2013-07-03 21:39:28 +01:00
John Cupitt 9cc8204ce1 vips_buildlut() works, removing old im_buildlut() 2013-07-03 14:01:46 +01:00
John Cupitt 7ee47c2073 vips_buildlut() builds
also fix ref doc build
2013-07-03 12:52:39 +01:00
John Cupitt 7490da07a6 rename image array as matrix
we had vips_image_new_array(), this was confusing with VIPS_TYPE_ARRAY,
something completely different ... rename image array as matrix
2013-07-02 22:09:50 +01:00
John Cupitt 2fd2fd58f7 fix up gtk-doc
fix various problems:

- out of date IGNORE in doc/reference/Makefile.am
- name clashes between private .h and public
2013-06-17 20:16:20 +01:00
John Cupitt 4c0ace34f0 docs cleanups 2013-06-17 14:54:11 +01:00
John Cupitt dad036afbf make a baseclass for the new create thing 2013-06-14 10:34:00 +01:00
John Cupitt d7d91363ba im_sines() as a class 2013-06-13 18:46:41 +01:00
John Cupitt 6031b40b8d move im_zone*() over to a class 2013-06-13 17:37:24 +01:00
John Cupitt 85e2092cdf start im_zone() 2013-06-13 14:55:33 +01:00
John Cupitt bfa8c85837 im_grey*() as a class 2013-06-13 14:35:26 +01:00
John Cupitt cf09f3376e redo im_*eye() as a class 2013-06-13 13:50:24 +01:00
John Cupitt 4436e370c7 make a "create" package
the old "other" package, plus move some of conversion in there
2013-06-13 10:12:22 +01:00