Commit Graph

377 Commits

Author SHA1 Message Date
Yonit Halperin
7cdf8de00a add stream report messages
If the server & client support SPICE_DISPLAY_CAP_STREAM_REPORT,
the server first sends SPICE_MSG_DISPLAY_STREAM_ACTIVATE_REPORT. Then,
the client periodically sends SPICE_MSGC_DISPLAY_STREAM_REPORT
messages that supply the server details about the current quality of
the video streaming on the client side. The server analyses the
report and adjust the stream parameters accordingly.
2013-04-22 11:34:20 -04:00
Christophe Fergeau
5ebeee5114 Add compile-time check for lz arrays
In addition to Laszlo's commit fixing rhbz#928973, we can add
some compile-time assertion to lz_common.h to help catch similar
bugs in the future.
This uses gnulib's verify.h to make sure at compile-time that
the various constant arrays used in lz_common.h are of the expected
size.
I've checked that before Laszlo's patch, the assert triggers, and
that it's gone after it.
2013-04-10 09:53:51 +02:00
Laszlo Ersek
5aa31e753f supply missing IS_IMAGE_TYPE_* elements for LZ_IMAGE_TYPE_A8
The IS_IMAGE_TYPE_PLT and IS_IMAGE_TYPE_RGB arrays are supposed to decide
whether each image type is PLT or RGB. Dependent on the result, one of the
PLT_PIXELS_PER_BYTE and RGB_BYTES_PER_PIXEL arrays can be indexed.

Commit c0b048eb introduced the LZ_IMAGE_TYPE_A8 enum constant and grew the
RGB_BYTES_PER_PIXEL array by one element, but it missed to append a zero
to IS_IMAGE_TYPE_PLT, and a one to IS_IMAGE_TYPE_RGB. Do so now.

Related RHBZ: 928973.

Signed-off-by: Laszlo Ersek <lersek@redhat.com>
2013-04-10 09:53:51 +02:00
Yonit Halperin
b52948d792 region.c: fix region_bounds_intersects
region_bounds_intersects mistakingly ignored one of the input regions,
and compared the other region to itself.
2013-04-02 08:45:42 -04:00
Hans de Goede
063f4dd385 Update spice-protocol
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2013-03-07 11:50:42 +01:00
Hans de Goede
1a83284e9c Update spice-protocol
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2013-03-04 19:41:59 +01:00
Michael Tokarev
149bb89adb Address a compilation warning due to missing typecast
Author: Serge Hallyn <serge.hallyn@ubuntu.com>

This is a trivial typecast fix, -- all surrounding
lines cast lines_end to PIXEL* but one is apparently
forgotten.  This fixes a compiler warning about
incompatible types in assignment.
2013-02-07 19:49:18 +01:00
Michael Tokarev
9ffc614a6c spice-common: remove version construction
Version string isn't used anywhere in spice-common, and there's
no version for spice-common module per se, either.  Hoever,
configure.ac has this:

 AC_INIT([spice-common],
         [m4_esyscmd(build-aux/git-version-gen .tarball-version)],
         [spice-devel@lists.freedesktop.org])

But since git-version-gen script is not provided in spice-common
module, multiple error messages are produced when generating
configure (running autogen/autoreconf), like this:

  sh: ./build-aux/git-version-gen: not found

(repeated about 50 times).

The following trivial patch removes usage of build-aux/git-version-gen
from AC_INIT and replaces it with a string "noversion", to stop
these scary messages from being produced.

Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
2013-02-07 19:33:14 +01:00
Yonit Halperin
df09927c3b canvas_base: fix not caching palettes that belong to images that are not rendered
Fixes: fedora 875348, 826036

When an image is not rendered, we still need to check if it contains
a palette that needs to be cached.
This bug caused the client to crash due to not finding palettes
in the cache.
2013-01-31 11:55:37 -05:00
Marc-André Lureau
c08e04b478 spice-protocol: updated submodule for new PROXY controller message 2013-01-28 15:44:54 +01:00
Hans de Goede
8a10919658 spice-common: Update spice-protocol to include VD_AGENT_CAP_SPARSE_MONITORS_CONFIG
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2013-01-18 14:26:49 +01:00
Dunrong Huang
81f40cca5f Update spice-protocol 2013-01-11 21:57:43 +01:00
Marc-André Lureau
b46d36bc1c Add a "port" channel
A Spice port channel carry arbitrary data between the Spice client and
the Spice server. It may be used to provide additional services on top
of a Spice connection. For example, a channel can be associated with
the qemu monitor for the client to interact with it, just like any
qemu chardev. Or it may be used with various protocols, such as the
Spice Controller.

A port kind is identified simply by its fqdn, such as org.qemu.monitor,
org.spice.spicy.test or org.ovirt.controller...

The channel is based on Spicevmc which simply tunnels data between
client and server. A few messages have been added:

SPICE_MSG_PORT_INIT: Describes the port state and fqdn name, should be
sent only once when the client connects.

SPICE_MSG_PORT_EVENT: Server port event. SPICE_PORT_EVENT_OPENED and
SPICE_PORT_EVENT_CLOSED are typical values when the chardev is opened
or closed.

SPICE_MSGC_PORT_EVENT: Client port event.
2012-12-05 11:24:05 +01:00
Marc-André Lureau
5f2e99c3da update spice-protocol 2012-12-05 11:24:05 +01:00
Alon Levy
be6392a5ad common/lz.c: improve lz_encode comment 2012-11-04 13:33:35 +02:00
Marc-André Lureau
8543d04cd2 ssl-verify: use more explicit error message
When the server certificate is not being signed by the provided CA,
the SSL debug message is currently for example:

ssl_verify.c:428:openssl_verify: openssl verify:num=19:self signed
certificate in certificate chain:depth=1:/C=IL/L=Raanana/O=Red
Hat/CN=my CA

Add a more explicit debug message too, as requested in bug:

https://bugzilla.redhat.com/show_bug.cgi?id=846666
2012-10-18 21:20:54 +02:00
Christophe Fergeau
222607814f Update spice-protocol submodule to 0.12.2 2012-09-21 15:53:09 +02:00
Christophe Fergeau
79502376d1 Update git.mk to latest version 2012-09-21 10:51:17 +02:00
Alon Levy
9b9592f80c Update spice-protocol module
Add support for client monitors config in qxl device.
2012-09-12 21:07:40 +03:00
Christophe Fergeau
f67bcd03e9 Update spice-protocol submodule
We need the latest spice-protocol to compile spice to get the A8
surface definitions
2012-09-10 10:45:26 +02:00
Marc-André Lureau
04dc2bee9e build-sys: remove Makefile from marshaller build dep
The release tarballs ship with the generated files to avoid extra
build work and dependency. However, build was still tiggering a
regenration, because of Makefile change.

Avoid required rebuild when running ./configure (generating Makefile),
there is no variable that could be tweaked, afaict.
2012-08-28 20:36:41 +02:00
Marc-André Lureau
86e286ba20 inputs: add a INPUTS_KEY_SCANCODE message
Add a new arbitrary keyboard scancodes message.

For now, it will be used to avoid unwanted key repeatition when there
is jitter in the network and too much time between DOWN and UP
messages, instead the client will send the press & release scancode in
a sequence.

See also: https://bugzilla.redhat.com/show_bug.cgi?id=812347
2012-08-27 17:12:07 +02:00
Alon Levy
2c55c9d0c6 configure.ac: support automake >= 1.12 2012-08-27 16:00:54 +03:00
Yonit Halperin
c2f58492ad support seamless migration
see spice-protocol for more details
commit 3838ad140a046c4ddf42fef58c9727ecfdc09f9f
2012-08-27 09:06:26 +03:00
Yonit Halperin
c6bd210ad0 add SPICE_MSG_MAIN_AGENT_CONNECTED_TOKENS
The msg is used for setting the number of allocated client tokens when
we notify the client that the agent is attached.
2012-08-27 09:02:05 +03:00
Søren Sandmann Pedersen
c0b048ebef Add support for A8 images to the LZ routines
This format is needed to add Render support to the X driver, so we
need the ability to compress and decompress it.
2012-08-24 13:37:51 -04:00
Søren Sandmann Pedersen
0c1b6de4ad canvas_utils: Make sure strides are aligned to multiple of 4
Pixman requires all strides to be aligned to a multiple of 4. With the
upcoming a8 images, this is not guaranteed anymore.
2012-08-13 11:54:04 -04:00
Marc-André Lureau
c2adbb00dc spice-common: don't install spice-protocol
Revert to usage of DIST_SUBDIRS to avoid make install under
spice-protocol. This is only possible since git.mk was fixed.
2012-08-09 12:44:41 +02:00
Marc-André Lureau
9768ebf80d Update git.mk to upstream version
wget https://raw.github.com/behdad/git.mk/master/git.mk
2012-08-09 12:44:41 +02:00
Marc-André Lureau
735e431671 build-sys: fix make distcheck
- don't try to overwrite read-only enums.h
- DIST_SUBDIRS is no longer needed
2012-07-16 17:35:08 +02:00
Alon Levy
7eba850ad5 support multiple monitors in single display channel
See spice-protocol commit for details:
 da908f89b581fd4725da997fdaea209f8e6548f6
 support multiple monitors on a single display channel
2012-07-12 19:50:40 +03:00
Alon Levy
b49c4794ee spice-protocol/spice/enums.h: rebuild from spice.proto
This file was hand generated until now, resulting in the wierd situation where
it is different for spice-gtk and spice-server even though they both use the
same spice-common and spice-protocol (or at least close) versions.

This patch generates the enums.h files from spice-common. While that file is
actually in the spice-protocol submodule, it cannot be generated from
spice-protocol since it lacks access to spice.proto and spice_codegen.py. So in
affect whenvever it will differ the spice-protocol module will become dirty and
hence hopefully commited with the new enums.h.

enums.h is generated from spice.proto is a superset of that generated from spice1.proto.
2012-07-08 18:12:18 +03:00
Alon Levy
2449260c81 common/log.h: add spice_info 2012-07-05 19:22:31 +03:00
Marc-André Lureau
f8f6231ecd Fix a gcc warning
warning: suggest explicit braces to avoid ambiguous 'else'
2012-06-30 02:54:53 +02:00
Marc-André Lureau
5020adc59f Fix invalid macro usage 2012-06-30 02:50:56 +02:00
Christophe Fergeau
bf5511033d ssl: more verbose output when SSL verification fails
This should make SSL connection failures easier to diagnose.
2012-06-25 14:59:59 +02:00
Alon Levy
800784df43 update spice-protocol for smartcard enums fix
d5d26cac49 broke spice-common by depending
on a local commit, fix it by depending on the now pushed commit.
2012-06-22 17:23:03 +03:00
Alon Levy
d40a181a20 Makefile.am: now that spice_codegen.py is used add *.pyc to ignored files in root 2012-06-20 16:25:33 +03:00
Alon Levy
9dff18a399 Makefile.am: fix .gitignore not being generated in spice-protocol/spice
By adding spice-protocol to SUBDIRS configure and make will be called in it.

Spotted by Marc-André.
2012-06-20 16:25:33 +03:00
Alon Levy
d5d26cac49 updated spice-protocol for smartcard enums non conflict with libcacard 2012-06-20 16:25:33 +03:00
Alon Levy
535b52db66 smartcard: build fixes for spice server
Define different enums that have a SPICE_ prefix to not conflict with same
value enums from libcacard/vsccard_common.h, and continue to use the same
SPICE_MSG_SMARTCARD_DATA and SPICE_MSGC_SMARTCARD_DATA enum that is used by the
server and clients (spice-gtk, spicec) alike.
2012-06-14 13:53:46 +03:00
Alon Levy
a976c16cf3 python_modules/ptypes.py/EnumBaseType.c_enumname: add missing return to fix broken enums generation
Fixes the resulting enums.h from the invocation of:
./spice_codegen.py --generate-enums spice.proto spice-protocol/spice/enums.h

Right now any enum will contain None as the enum members, with this fix
it will contain the real enum members, i.e. SPICE_FOO.
2012-06-14 13:53:46 +03:00
Marc-André Lureau
5f44094940 ssl-verify: add a bit of run-time checks
Even if they are not public functions, those conditions can be reached
in a invalid state.
2012-05-17 14:38:28 +02:00
Yonit Halperin
22fc0b0145 video streaming: add support for frames of different sizes
rhbz #813826, #815426

Add SPICE_MSG_DISPLAY_STREAM_DATA_SIZED, for stream_data message
that also contains the size and destination box of the data.
The server can send such messages only to clients with
SPICE_DISPLAY_CAP_SIZED_STREAM.
2012-05-02 14:47:29 +03:00
Yonit Halperin
178c7eaff6 region: add region_extents 2012-05-02 14:47:27 +03:00
Yonit Halperin
cbf423f833 rect: add rect_debug 2012-05-02 14:47:26 +03:00
Yonit Halperin
ffeb6ce677 rect: add rect_get_area 2012-05-02 14:47:26 +03:00
Yonit Halperin
2e4b605272 rect: add rect_contains 2012-05-02 14:47:26 +03:00
Jeremy White
f37ba0d032 Set the clip type to reflect the on wire type. 2012-04-26 19:47:10 +03:00
Daniel P. Berrange
ff25524948 Add missing struct field initializers
Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
2012-04-25 14:23:31 +01:00