Akita Noek
e8a58f7c75
Added #include <string.h> to PNG.h for inlined memcpy usage
12 years ago
King Koopa
14d9f587b6
Added another optional argument for setting row filters.
12 years ago
King Koopa
81bc5d79a9
More cleanup.
12 years ago
King Koopa
e2a5ed2b05
Cleaned up code and added the same fix to Canvas::StreamPngSync
12 years ago
King Koopa
50d0c5c55f
Added compression level argument to Canvas::toBuffer
12 years ago
King Koopa
c3ed7faca1
Initial commit of extracted PNG creation.
12 years ago
Daniel Beardsley
d72c1bbf02
JPEGStream: add progressive mode option
Progressive jpegs have several very useful advantages over baseline
jpegs:
* Slightly smaller for the same quality (3-7%)
* Load much faster in most browsers.
This adds the `options.progressive` option to the
canvas.jpegCreateStream() function.
12 years ago
mscdex
9f5ce29777
Fix immediate variable reassignment
12 years ago
mscdex
fd56f06e87
Fix resource leaks on read errors
12 years ago
Rod Vagg
2354d9bb8c
0.11.4+ compatibility using NAN
See https://github.com/rvagg/nan
12 years ago
TJ Holowaychuk
4686fa3b97
Revert "Fixed Error that prevented NPM install on mac."
This reverts commit 92d8e84a6d
.
incorrect
12 years ago
Infinite Whiteboard
13b8f41141
Added backwards compatibility through conditional compilation.
12 years ago
Infinite Whiteboard
14a19421d2
Patch for Node 0.11.3
12 years ago
Victor Goya
93bb98d440
loadJPEG: fix fread() return value testing
According to the fread() manpage, successful fread() call will return 1 and not len in this case.
12 years ago
pb82
ba3bb3137e
removed unneeded private fields
12 years ago
Seth Fitzsimmons
8dc36f09fa
CanvasRenderingContext2d#filter
Like patternQuality, but applies to transformations effecting more than just
patternsi (i.e. the implicitly created pattern).
See
http://cairographics.org/manual/cairo-cairo-pattern-t.html#cairo-pattern-set-filter
for more information.
12 years ago
Seth Fitzsimmons
a1fa149551
Add 'nearest' and 'bilinear' to patternQuality
12 years ago
Matthew Borden
92d8e84a6d
Fixed Error that prevented NPM install on mac.
NPM spat out a error that there was only 2 params in DGIFOPEN. I added
the third, an error interger.
12 years ago
TJ Holowaychuk
ef897a2a2c
ocd
12 years ago
Julian Viereck
1d3a99d85a
Add support to load fonts from file.
12 years ago
Nathan Rajlich
8a5349e525
explicitly cast the after work callback function to "uv_after_work_cb"
for node >= v0.9.4 compat
12 years ago
Chris Spencer
cfc6dfd714
Call cairo_surface_finish in ~Canvas when pdf
Fixes an issue where when a pdf surface isn't buffered and then is
garbage collected, the toBuffer can be called and attempt to realloc
the destroyed closure.
12 years ago
Mark Cochran
4a3caeb25f
Adding support for grayscale JPEG.
13 years ago
Luigi Pinca
25234db5df
Fix cases where GIF_LIB_VERSION is not defined
Versions up to 4.1.6 of GIFLIB defined a GIF_LIB_VERSION macro that was string-valued.
Versions after 4.1.6 define integer-valued GIFLIB_MAJOR, GIFLIB_MINOR, and GIFLIB_RELEASE macros for the three components of the version.
Check for GIF_LIB_VERSION, otherwise use the new macros.
13 years ago
Nathan Rajlich
718e868682
init: fix cases where JPEG_LIB_VERSION_MAJOR/MINOR are not defined
First fall back to trying to use JPEG_LIB_VERSION.
Then if that's not available, then set them both to 0.
Fixes #202 .
13 years ago
Luigi Pinca
a7615ceb91
Fixed an issue with jpeg-turbo library
There were compilation errors if the version of the library was less than 1.2.0.
This was happening because the macros JPEG_LIB_VERSION_MAJOR and JPEG_LIB_VERSION_MINOR were not being defined, since the compile-time macro LIBJPEG_TURBO_VERSION was introduced in version 1.2.0.
The problem was fixed by giving those two macros a definition if it was missing.
13 years ago
c-spencer
474635d526
Fix Context2d::SetFont for pango when setting normal weight/style
13 years ago
c-spencer
3388ab5b33
Properly dispose of pango related allocations in ~Context2d()
13 years ago
c-spencer
efadaead73
Add measureText implementation for pango
13 years ago
c-spencer
8e9defcb79
Tidy up build files and util script.
13 years ago
c-spencer
50ab677036
Use strndup for duplicating fontFamily strings.
13 years ago
TJ Holowaychuk
f5985af0f1
fix closure_destroy() with cast for AdjustAmountOfExternalAllocatedMemory()
13 years ago
TJ Holowaychuk
1cae3db2d0
Revert "Fixes #182"
This reverts commit 02041571ce
.
13 years ago
c-spencer
35d491a284
Add pango drawing support, and silence some warnings.
13 years ago
c-spencer
d3f3a94835
Add simple support for using jpeg-turbo library.
13 years ago
Luigi Pinca
02041571ce
Fixes #182
13 years ago
Nathan Rajlich
7cf35c8396
export the "gifVersion" when compiled with gif support
13 years ago
Nathan Rajlich
ba234eaae1
export the "jpegVersion" when compiled with jpeg support
13 years ago
Nathan Rajlich
0e4fa461de
src: add newline at end of file to fix compiler warning
13 years ago
Nathan Rajlich
cdb2421812
build: begin making gyp file work on unix
13 years ago
TJ Holowaychuk
f5be948340
fix jpeg malloc Image issue. Closes #160 [c-spencer]
13 years ago
Andreas Botsikas
3738179d76
Added instructions, binding.gyp and added the NODE_MODULE macro to specify the entry point.
13 years ago
TJ Holowaychuk
f47422fd06
fixed Image bit flags
13 years ago
TJ Holowaychuk
69d4eb3987
slight refactor
13 years ago
c-spencer
03584c3307
Improve Image mode API
13 years ago
c-spencer
4c5962b90e
Add clearData method to handle reassignment of src, and clean up mime data memory handling.
13 years ago
c-spencer
cc994d2d8d
Improve how _data_len is managed and use to adjust memory, hide more of mime API behind cairo version conditional.
13 years ago
c-spencer
8b8ee7f017
Add optional mime-data tracking to Image.
13 years ago
c-spencer
d5838bc4aa
Refactor JPEG decoding into decodeJPEGIntoSurface
13 years ago
c-spencer
307fa29396
Switch draw mode state to an enum.
13 years ago