Added ifdef to force fast (less compressed) PNG rendering only when asked.
This commit is contained in:
parent
b16eda0d48
commit
18e01ee74c
@ -330,11 +330,13 @@ int guac_send_png(GUACIO* io, int layer, int x, int y, png_byte** png_rows, int
|
|||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef GUAC_FAST_PNG
|
||||||
/* Do not filter (speed) */
|
/* Do not filter (speed) */
|
||||||
png_set_filter(png, PNG_FILTER_TYPE_BASE, PNG_FILTER_VALUE_NONE);
|
png_set_filter(png, PNG_FILTER_TYPE_BASE, PNG_FILTER_VALUE_NONE);
|
||||||
|
|
||||||
/* Fast compression level */
|
/* Fast compression level */
|
||||||
png_set_compression_level(png, 1);
|
png_set_compression_level(png, 1);
|
||||||
|
#endif
|
||||||
|
|
||||||
/* Set error handler */
|
/* Set error handler */
|
||||||
if (setjmp(png_jmpbuf(png))) {
|
if (setjmp(png_jmpbuf(png))) {
|
||||||
|
Loading…
Reference in New Issue
Block a user