Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GUACAMOLE-377: Add libguac "guac_display" API for easy and efficient rendering. #525

Open
wants to merge 39 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
6346ae5
GUACAMOLE-377: Establish public guac_display API for efficient render…
mike-jumper Jun 3, 2024
8da2131
GUACAMOLE-377: Tighten dirty rects down to the individual pixel, rath…
mike-jumper Jun 12, 2024
0952cd1
GUACAMOLE-377: Update layer list head upon layer removal only if non-…
mike-jumper Jun 13, 2024
dec098e
GUACAMOLE-377: Do NOT acquire the ops lock before any frame lock.
mike-jumper Jun 13, 2024
ee0bc77
GUACAMOLE-377: Correct logic and lock order around deferred frame flu…
mike-jumper Jun 13, 2024
dc24806
GUACAMOLE-377: Clarify logic around opaque layers.
mike-jumper Jun 13, 2024
d52484f
GUACAMOLE-377: Ensure regions outside last frame bounds are considere…
mike-jumper Jun 18, 2024
71db4be
GUACAMOLE-377: Migrate guac_mem_*() assertions to GUAC_ASSERT().
mike-jumper Jun 8, 2024
0ae0d61
GUACAMOLE-377: Do not render frames while users are joining.
mike-jumper Jun 18, 2024
4486cef
GUACAMOLE-377: Flush an automatic frame for mouse changes only if the…
mike-jumper Jun 18, 2024
eaeee91
GUACAMOLE-377: Updates to cursor must occur within the boundary of th…
mike-jumper Jun 19, 2024
0576868
GUACAMOLE-377: Ensure all layers supporting transparency are properly…
mike-jumper Jun 19, 2024
924326a
GUACAMOLE-377: Add ability to "hint" that a drawing operation copied …
mike-jumper Jun 19, 2024
202f217
GUACAMOLE-377: Use 2 worker threads per available processor.
mike-jumper Aug 7, 2024
c9b42c8
GUACAMOLE-377: Do not use threaded WebP encoder given that guac_displ…
mike-jumper Aug 7, 2024
8630f76
GUACAMOLE-377: Migrate VNC support to guac_display API.
mike-jumper Jun 4, 2024
e8edffa
GUACAMOLE-377: Group all guac_display documentation together under a …
mike-jumper Aug 7, 2024
66e7e0f
GUACAMOLE-377: Migrate RDP to guac_display.
mike-jumper Aug 18, 2024
31cb837
GUACAMOLE-377: Replace RDP settings string (rather than reuse storage…
mike-jumper Sep 18, 2024
c2a8172
GUACAMOLE-377: Use FreeRDP's built-in GDI handling of bitmap cache.
mike-jumper Aug 31, 2024
7ae4d79
GUACAMOLE-377: Migrate terminal emulator to guac_display.
mike-jumper Aug 8, 2024
28be379
GUACAMOLE-377: Work around libssh2 usage of strlen() on key data (oth…
mike-jumper Sep 1, 2024
8504cf7
GUACAMOLE-377: Increase maximum number of streams.
mike-jumper Aug 18, 2024
2794aba
GUACAMOLE-377: Ignore directories and files used by Clang compilation…
mike-jumper Aug 16, 2024
a946ec1
GUACAMOLE-377: Correct return value confusion in handling of timeout …
mike-jumper Aug 20, 2024
5f22294
GUACAMOLE-377: Prefer GUAC_COMP_OVER to GUAC_COMP_SRC for performance…
mike-jumper Aug 24, 2024
00f4109
GUACAMOLE-377: Remove all old surface, display, cursor, and rect code…
mike-jumper Aug 28, 2024
ed3b6e5
GUACAMOLE-377: Ensure frame boundaries are sent even for frames conta…
mike-jumper Sep 1, 2024
2e48442
GUACAMOLE-377: Migrate from timer to thread for pending users.
mike-jumper Sep 1, 2024
71ac0ff
GUACAMOLE-377: Restore heuristic detection of RDP frame boundaries.
mike-jumper Sep 9, 2024
c590468
GUACAMOLE-377: Restore heuristic detection of VNC frame boundaries.
mike-jumper Sep 9, 2024
1a82bc6
GUACAMOLE-377: Allow the pending frame buffer for a guac_display_laye…
mike-jumper Sep 11, 2024
60fe646
GUACAMOLE-377: Migrate RDP to direct access of FreeRDP's GDI buffer.
mike-jumper Sep 11, 2024
a0aed0b
GUACAMOLE-377: Migrate VNC to direct access of RFB framebuffer.
mike-jumper Sep 11, 2024
5189bf3
GUACAMOLE-377: Wrap all message handling within drawing context.
mike-jumper Sep 14, 2024
04becb0
GUACAMOLE-377: Remove unnecessary locking of last frame during resize.
mike-jumper Sep 18, 2024
0197863
GUACAMOLE-377: Restore good ol' guac_common_surface and guac_common_c…
mike-jumper Sep 5, 2024
e643e73
GUACAMOLE-377: Revert migration of terminal emulator to guac_display.
mike-jumper Sep 5, 2024
4df0b71
GUACAMOLE-377: Make vertical combination more likely by limiting comb…
mike-jumper Sep 20, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -48,3 +48,7 @@ doc/*/doxygen-output

# IDE metadata
nbproject/

# Compilation database, as may be generated by tools like Bear
jmuehlner marked this conversation as resolved.
Show resolved Hide resolved
.cache/
compile_commands.json
5 changes: 5 additions & 0 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,14 @@ PKG_PROG_PKG_CONFIG()
AC_CHECK_HEADERS([fcntl.h stdlib.h string.h sys/socket.h time.h sys/time.h syslog.h unistd.h cairo/cairo.h pngstruct.h])

# Source characteristics
AC_DEFINE([_GNU_SOURCE], [1], [Uses GNU-specific APIs (if available)])
AC_DEFINE([_XOPEN_SOURCE], [700], [Uses X/Open and POSIX APIs])
AC_DEFINE([__BSD_VISIBLE], [1], [Uses BSD-specific APIs (if available)])

# Check for availability of non-portable sched_getaffinity() function (one of
# several possible routes for determining the number of available processors)
AC_CHECK_FUNCS([sched_getaffinity])

# Check for whether math library is required
AC_CHECK_LIB([m], [cos],
[MATH_LIBS=-lm],
Expand Down
13 changes: 10 additions & 3 deletions src/common-ssh/key.c
Original file line number Diff line number Diff line change
Expand Up @@ -132,18 +132,25 @@ guac_common_ssh_key* guac_common_ssh_key_alloc(char* data, int length,
* different key algorithms) we need to perform a heuristic here to check
* if a passphrase is needed. This could allow junk keys through that
* would never be able to auth. libssh2 should display errors to help
* admins track down malformed keys and delete or replace them.
*/
* admins track down malformed keys and delete or replace them. */

if (is_passphrase_needed(data, length) && (passphrase == NULL || *passphrase == '\0'))
return NULL;

guac_common_ssh_key* key = guac_mem_alloc(sizeof(guac_common_ssh_key));

/* NOTE: Older versions of libssh2 will at times ignore the declared key
* length and instead recalculate the length using strlen(). This has since
* been fixed, but as of this writing the fix has not yet been released.
* Below, we add our own null terminator to ensure that such calls to
* strlen() will work without issue. We can remove this workaround once
* copies of libssh2 that use strlen() on key data are not in common use. */

/* Copy private key to structure */
key->private_key_length = length;
key->private_key = guac_mem_alloc(length);
key->private_key = guac_mem_alloc(guac_mem_ckd_add_or_die(length, 1)); /* Extra byte added here for null terminator (see above) */
memcpy(key->private_key, data, length);
jmuehlner marked this conversation as resolved.
Show resolved Hide resolved
key->private_key[length] = '\0'; /* Manually-added null terminator (see above) */
key->passphrase = guac_strdup(passphrase);

return key;
Expand Down
2 changes: 0 additions & 2 deletions src/common/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ noinst_HEADERS = \
common/clipboard.h \
common/cursor.h \
common/defaults.h \
common/display.h \
common/dot_cursor.h \
common/ibar_cursor.h \
common/iconv.h \
Expand All @@ -51,7 +50,6 @@ libguac_common_la_SOURCES = \
blank_cursor.c \
clipboard.c \
cursor.c \
display.c \
dot_cursor.c \
ibar_cursor.c \
iconv.c \
Expand Down
293 changes: 0 additions & 293 deletions src/common/common/display.h

This file was deleted.

Loading
Loading