Compare commits
No commits in common. "pristine-tar" and "master" have entirely different histories.
pristine-t
...
master
241
CHANGELOG.md
Normal file
241
CHANGELOG.md
Normal file
@ -0,0 +1,241 @@
|
||||
Major changes in 0.14.3
|
||||
=======================
|
||||
* Add VD_AGENT_CLIPBOARD_FILE_LIST to support copy/paste of files with
|
||||
WebDAV support
|
||||
* Add support for side mouse buttons
|
||||
* Add a MonitorsMM field to VDAgentMonitorsConfig allowing to pass
|
||||
physical monitor dimension
|
||||
|
||||
Major changes in 0.14.2
|
||||
=======================
|
||||
* Removed Autoconf support, only Meson is available
|
||||
* Removed foreign-menu and controller interfaces
|
||||
* Deprecated CELT support
|
||||
* Generate MingW packages building the RPM
|
||||
* Allows for the agent to pass back a more specific error to the client
|
||||
* Add quality indicators messages
|
||||
|
||||
Major changes in 0.14.1
|
||||
=======================
|
||||
* This is the last release with:
|
||||
* Autotools: Meson is now the only supported
|
||||
* foreign_menu_prot.h: Deprecated in this release
|
||||
* controller_prot.h: Deprecated in this release
|
||||
* Add VD_AGENT_CAP_CLIPBOARD_NO_RELEASE_ON_REGRAB
|
||||
* Add VD_AGENT_CAP_CLIPBOARD_GRAB_SERIAL
|
||||
* Add SPICE_MSGC_MAIN_QUALITY_INDICATOR enum
|
||||
* Add STREAM_TYPE_QUALITY_INDICATOR message
|
||||
* Remove deprecated vdi_dev.h interface
|
||||
* Remove deprecated VD_AGENT_CLIPBOARD_MAX_SIZE_DEFAULT
|
||||
* Remove deprecated VD_AGENT_CLIPBOARD_MAX_SIZE_ENV
|
||||
* Remove unused SPICE_GNUC_ macros
|
||||
* qxl_dev: QXLReleaseInfo alignment fix
|
||||
* Some documentation added in vd_agentd.h
|
||||
* Now shipping a rpm spec file to easy deployment and testing
|
||||
|
||||
Major changes in 0.14.0
|
||||
=======================
|
||||
* Bumping minor to show that some types and values were removed
|
||||
* Regenerate enums.h (from spice.proto) which removes:
|
||||
* SpicePubkeyType;
|
||||
* SpiceTunnelServiceType;
|
||||
* SpiceTunnelIpType;
|
||||
* SPICE_MSG_TUNNEL_* and SPICE_MSGC_TUNNEL_*
|
||||
* Add VDAgentGraphicsDeviceInfo message
|
||||
* Add StreamMsgGraphicsDeviceInfo message
|
||||
* Add padding to SpiceStat structure
|
||||
|
||||
Major changes in 0.12.15
|
||||
========================
|
||||
* Add support for h265 video codec
|
||||
* qxl_dev: Align QXLRam to 4 bytes
|
||||
* meson: fix spice-protocol as subproject
|
||||
|
||||
Major changes in 0.12.14
|
||||
========================
|
||||
* add stream-device protocol
|
||||
* add SPICE_SURFACE_FLAGS_STREAMING_MODE flag
|
||||
* add e2k (Elbrus 2000) architecture
|
||||
* add SPICE_MAX_NUM_STREAMS
|
||||
* add meson support
|
||||
* add bult-ins byte swapping for Visual C++
|
||||
* switch to built-ins byte swapping in GCC
|
||||
|
||||
Major changes in 0.12.13
|
||||
========================
|
||||
* add DISPLAY_PREFERRED_VIDEO_CODEC_TYPE
|
||||
* add VP9 codec type
|
||||
* add VD_AGENT_CLEAR_CAPABILITY() macro
|
||||
* add VD_AGENT_CAP_FILE_XFER_DISABLED
|
||||
* add VD_AGENT_FILE_XFER_STATUS_NOT_ENOUGH_SPACE
|
||||
* add new file-xfer statuses for detailed error
|
||||
* Change enums.h license to MIT
|
||||
|
||||
Major changes in 0.12.12
|
||||
========================
|
||||
* protocol: Add lz4 compression support to the SpiceVMC channel
|
||||
|
||||
Major changes in 0.12.11
|
||||
========================
|
||||
* protocol: add support for the VP8 and h264 video codecs
|
||||
* protocol: add unix GL scanout messages
|
||||
* remove code generation scripts, moved back to spice-common
|
||||
* macros improvements, more type safety
|
||||
|
||||
Major changes in 0.12.10
|
||||
========================
|
||||
* Add VD_AGENT_CAP_MONITORS_CONFIG_POSITION to handle multi-monitor
|
||||
configurations that are not multi-head
|
||||
* Add protocol code generation scripts from spice-common
|
||||
* Endianness and compiler portability fixes (clang)
|
||||
|
||||
Major changes in 0.12.9
|
||||
=======================
|
||||
* rename newly introduced SpiceImageCompress enum to SpiceImageCompression
|
||||
as otherwise it was clashing with the definition used by older spice-server
|
||||
releases, breaking QEMU build
|
||||
|
||||
Major changes in 0.12.8
|
||||
=======================
|
||||
* add LZ4 support
|
||||
* add audio volume synchronization
|
||||
* deprecate unused vdi-dev
|
||||
* add 'preferred-compression' message/capability
|
||||
* add a new Windows driver escape code to send
|
||||
monitors capability from guest to client
|
||||
|
||||
Major changes in 0.12.7
|
||||
=======================
|
||||
* add support for Webdav channel
|
||||
* add support for the Opus codec
|
||||
|
||||
Major changes in 0.12.6
|
||||
=======================
|
||||
* add adaptive video streaming support:
|
||||
control playback latency and receive playback
|
||||
reports from the client.
|
||||
* add agent capabilities for signaling guest line ending.
|
||||
|
||||
Major changes in 0.12.5
|
||||
=======================
|
||||
* Add agent file xfer success status
|
||||
* Add a client-disconnected agent message
|
||||
|
||||
Major changes in 0.12.4
|
||||
=======================
|
||||
* Add agent file copy support.
|
||||
* Add agent sparse monitors capability.
|
||||
* Add controller proxy message.
|
||||
|
||||
Major changes in 0.12.3
|
||||
=======================
|
||||
* Add a generic "port" channel
|
||||
|
||||
Major changes in 0.12.2
|
||||
=======================
|
||||
* Add A8 surface capability in display channel.
|
||||
* Add to qxl device support for:
|
||||
* client present
|
||||
* client capabilities
|
||||
* client monitors configuration
|
||||
|
||||
Major changes in 0.12.1
|
||||
=======================
|
||||
* Support seamless migration.
|
||||
* New QXLComposite message for better X support.
|
||||
* Support arbitrary scancode message INPUTS_KEY_SCANCODE.
|
||||
|
||||
Major changes in 0.12.0
|
||||
=======================
|
||||
* Add support for arbitrary resolution on Windows QXL with
|
||||
QXL_ESCAPE_SET_CUSTOM_DISPLAY
|
||||
* Add support for arbitrary resolution and multiple monitor per
|
||||
display channel with QXLMonitorsConfig and co
|
||||
* build cleanup
|
||||
|
||||
Major changes in 0.10.3 (0.10.2 was never released)
|
||||
===================================================
|
||||
* Add support for video streams with differently sized (wxh) data
|
||||
* Add controller messages for USB redirection, COLOR_DEPTH, DISABLE_EFFECTS,
|
||||
and ENABLE_SMARTCARD
|
||||
* Add name & uuid messages on main channel
|
||||
* some cleanups
|
||||
* Fixes RHBZ#815422, RHBZ#807295, RHBZ#787447
|
||||
|
||||
Major changes in 0.10.1
|
||||
=======================
|
||||
* Add support for a header without sublist and serial (mini header)
|
||||
|
||||
Major changes in 0.10.0
|
||||
=======================
|
||||
* no changes, released to match version with spice
|
||||
|
||||
Major changes in 0.9.1 (same as 0.8.2 in 0.8 branch)
|
||||
======================
|
||||
* Add support for semi-seamless migration
|
||||
|
||||
Major changes in 0.9.0
|
||||
======================
|
||||
* Add support for generic spicevmc chardev passthrough messages
|
||||
* Add USB redirection channel
|
||||
|
||||
Major changes in 0.8.1
|
||||
======================
|
||||
* Add support for volume change
|
||||
* Add support for async guest io writes and interrupt
|
||||
* Add support for suspend related guest io writes
|
||||
* Add support for interrupt indicating guest bug
|
||||
|
||||
Major changes in 0.8.0
|
||||
======================
|
||||
* Add support for different clipboards (selections) to vd_agent copy paste
|
||||
* Add support for using different authentication mechanisms (just SASL for now)
|
||||
|
||||
Major changes in 0.7.1
|
||||
======================
|
||||
* Add some enums for the xorg qxl driver
|
||||
* Some other small fixes
|
||||
|
||||
Major changes in 0.7.0
|
||||
======================
|
||||
* Add smartcard channel
|
||||
|
||||
Major changes in 0.6.4
|
||||
======================
|
||||
* Make controller client protocol menu text UTF8 rather then 16 bit unicode
|
||||
|
||||
Major changes in 0.6.3:
|
||||
=======================
|
||||
* Add support for copy and paste to the agent protocol
|
||||
* Add foreign-menu and external controller client protocol headers
|
||||
|
||||
Major changes in 0.6.2:
|
||||
=======================
|
||||
* Skipped to stay in sync with spice
|
||||
|
||||
Major changes in 0.6.1:
|
||||
=======================
|
||||
* Added compat flag for 16bpp commands
|
||||
|
||||
Major changes in 0.6.0:
|
||||
=======================
|
||||
* Initial messages for clipboard sharing
|
||||
* Move agent protocol structs from spice to spice-protocol
|
||||
* Add capabilities to agent protocol
|
||||
|
||||
Major changes in 0.5.3:
|
||||
=======================
|
||||
|
||||
Network major number changed to 2 to reflect that the network
|
||||
protocol is now stable and backwards compatible from this point.
|
||||
|
||||
Some vdagent messages for display settings and clipboard sharing
|
||||
were added.
|
||||
|
||||
Major changes in 0.5.2:
|
||||
=======================
|
||||
|
||||
This is the first release of the unstable 0.5.x series leading up to 0.6.
|
||||
This module was split out of spice so that e.g. drivers and qemu can
|
||||
get the types and constants they need without using the full spice
|
||||
codebase.
|
||||
25
COPYING
Normal file
25
COPYING
Normal file
@ -0,0 +1,25 @@
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are
|
||||
met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
* Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in
|
||||
the documentation and/or other materials provided with the
|
||||
distribution.
|
||||
* Neither the name of the copyright holder nor the names of its
|
||||
contributors may be used to endorse or promote products derived
|
||||
from this software without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS "AS
|
||||
IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
||||
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
||||
PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
27
README.md
Normal file
27
README.md
Normal file
@ -0,0 +1,27 @@
|
||||
spice-protocol
|
||||
==============
|
||||
|
||||
The protocol definition for [SPICE] project used by:
|
||||
* [spice-server]: A server side library used by [QEMU] and [x11spice];
|
||||
* [spice-gtk]: A client side library used by [virt-viewer and virt-manager] and
|
||||
[GNOME Boxes];
|
||||
* [linux/vd-agent] and [win32/vd-agent]: Guest components for Linux and Windows
|
||||
* [xf86-video-qxl], [gpu/drm/qxl], [win32/qxl], [win32/qxl-wddm-dod]: Guest video
|
||||
drivers;
|
||||
|
||||
Please [report bugs] at Freedesktop's instance of Gitlab
|
||||
|
||||
[SPICE]: https://spice-space.org
|
||||
[spice-server]: https://gitlab.freedesktop.org/spice/spice
|
||||
[QEMU]: https://www.qemu.org
|
||||
[x11spice]: https://gitlab.com/spice/x11spice
|
||||
[spice-gtk]: https://gitlab.freedesktop.org/spice/spice-gtk
|
||||
[virt-viewer and virt-manager]: https://virt-manager.org/
|
||||
[GNOME Boxes]: https://wiki.gnome.org/Apps/Boxes
|
||||
[linux/vd-agent]: https://gitlab.freedesktop.org/spice/linux/vd_agent
|
||||
[win32/vd-agent]: https://gitlab.freedesktop.org/spice/win32/vd_agent
|
||||
[xf86-video-qxl]: https://gitlab.freedesktop.org/xorg/driver/xf86-video-qxl
|
||||
[gpu/drm/qxl]: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/gpu/drm/qxl
|
||||
[win32/qxl]: https://gitlab.freedesktop.org/spice/win32/qxl
|
||||
[win32/qxl-wddm-dod]: https://gitlab.freedesktop.org/spice/win32/qxl-wddm-dod
|
||||
[report bugs]: https://gitlab.freedesktop.org/spice/spice-protocol/issues/
|
||||
207
debian/changelog
vendored
Normal file
207
debian/changelog
vendored
Normal file
@ -0,0 +1,207 @@
|
||||
spice-protocol (0.14.3-2) unstable; urgency=medium
|
||||
|
||||
Add support for AV1 codec [amf vaapi qsv nvenc]
|
||||
Add support for H265 codec [amf vaapi qsv nvenc]
|
||||
Add support for H264 codec [amf vaapi qsv nvenc]
|
||||
Add support for MJPEG codec [vaapi nvjpg]
|
||||
|
||||
-- Lierfang Support Team <itsupport@lierfang.com> Fri, 21 May 2025 15:45:00 +0300
|
||||
|
||||
spice-protocol (0.14.3-1) unstable; urgency=medium
|
||||
|
||||
* New upstream version 0.14.3 (Closes: #976333)
|
||||
* d/watch: allow .xz extension too (upstream switched to it at 0.14.3)
|
||||
* use meson to build spice-protocol (add it to Build-Depends)
|
||||
* remove references to removed files from d/copyright
|
||||
(spice/controller_prot.h spice/foreign_menu_prot.h)
|
||||
* hack: remove arch-specific but unused libdir= assignment
|
||||
in generated spice-protocol.pc
|
||||
|
||||
-- Michael Tokarev <mjt@tls.msk.ru> Fri, 04 Dec 2020 15:45:00 +0300
|
||||
|
||||
spice-protocol (0.14.1-2) unstable; urgency=medium
|
||||
|
||||
[ Laurent Bigonville ]
|
||||
* debian/docs: Install the README.md and CHANGELOG.md files
|
||||
|
||||
[ Michael Tokarev ]
|
||||
* set Maintainer to the QEMU team (Closes: #911429)
|
||||
* set VCS links to point to qemu-team on salsa
|
||||
* use secure (https) URLs in d/control & d/copyright
|
||||
|
||||
-- Michael Tokarev <mjt@tls.msk.ru> Thu, 23 Jul 2020 15:22:04 +0300
|
||||
|
||||
spice-protocol (0.14.1-1) unstable; urgency=medium
|
||||
|
||||
* Team upload.
|
||||
* New upstream release
|
||||
* debian/gbp.conf: Enable pristine-tar
|
||||
* Bump Standards-Version to 4.5.0 (no further changes)
|
||||
* Bump debhelper compatibility to 12
|
||||
|
||||
-- Laurent Bigonville <bigon@debian.org> Sat, 25 Apr 2020 12:18:50 +0200
|
||||
|
||||
spice-protocol (0.14.0-1) unstable; urgency=medium
|
||||
|
||||
* Team upload.
|
||||
[ Ondřej Nový ]
|
||||
* d/copyright: Change Format URL to correct one
|
||||
* d/changelog: Remove trailing whitespaces
|
||||
* d/control: Remove trailing whitespaces
|
||||
|
||||
[ Laurent Bigonville ]
|
||||
* Enable upstream tarball signature verification
|
||||
* New upstream version 0.14.0
|
||||
* debian/docs: Dropped, the NEWS file has been renamed to CHANGELOG.md and
|
||||
is now installed by dh_installchangelogs
|
||||
* debian/control: Bump Standards-Version to 4.4.0 (no further changes)
|
||||
|
||||
-- Laurent Bigonville <bigon@debian.org> Fri, 02 Aug 2019 12:01:46 +0200
|
||||
|
||||
spice-protocol (0.12.14-1) unstable; urgency=medium
|
||||
|
||||
* Team upload.
|
||||
* debian/control: Update the Vcs-* fields to point to salsa
|
||||
* New upstream version 0.12.14 (Closes: #904075)
|
||||
* debian/control: Bump Standards-Version to 4.2.1 (no further changes)
|
||||
* Bump debhelper compatibility to 11
|
||||
* debian/watch: Use https:// instead of http://
|
||||
* debian/rules: Disable DH_VERBOSE by default
|
||||
|
||||
-- Laurent Bigonville <bigon@debian.org> Wed, 29 Aug 2018 17:14:51 +0200
|
||||
|
||||
spice-protocol (0.12.13-2) unstable; urgency=medium
|
||||
|
||||
* Mark libspice-protocol-dev Multi-Arch: foreign. (Closes: #842476)
|
||||
Thanks to Helmut Grohne <helmut@subdivi.de>
|
||||
|
||||
-- Liang Guo <guoliang@debian.org> Sun, 06 Aug 2017 18:18:49 +0800
|
||||
|
||||
spice-protocol (0.12.13-1) unstable; urgency=low
|
||||
|
||||
* New upstream release
|
||||
* Update debian/copyright, spice/enums.h license change
|
||||
* Bump Standards-Version to 4.0.0 (no changes needed)
|
||||
|
||||
-- Liang Guo <guoliang@debian.org> Sun, 06 Aug 2017 16:26:56 +0800
|
||||
|
||||
spice-protocol (0.12.12-1) unstable; urgency=low
|
||||
|
||||
* New upstream release
|
||||
|
||||
-- Liang Guo <guoliang@debian.org> Sat, 08 Oct 2016 21:22:00 +0800
|
||||
|
||||
spice-protocol (0.12.11-1) unstable; urgency=medium
|
||||
|
||||
* New upstream release
|
||||
* Bump Standards-Version to 3.9.8 (no changes needed)
|
||||
* Use secure uri in vcs*
|
||||
* Bump compat version to 9
|
||||
* debian/copyright:
|
||||
- Merge paragraphs with same shot name
|
||||
- Correct wrong shot license name
|
||||
|
||||
-- Liang Guo <guoliang@debian.org> Wed, 22 Jun 2016 13:38:19 +0800
|
||||
|
||||
spice-protocol (0.12.10-1) unstable; urgency=medium
|
||||
|
||||
* New upstream release
|
||||
* fixed vcs http url
|
||||
|
||||
-- Michael Tokarev <mjt@tls.msk.ru> Thu, 08 Oct 2015 21:55:44 +0300
|
||||
|
||||
spice-protocol (0.12.7-1) unstable; urgency=medium
|
||||
|
||||
* New upstream release
|
||||
* Add mjt to uploaders
|
||||
* Remove ${shlibs:Depends} as we're only shipping headers
|
||||
* Bump Standards-Version to 3.9.5 (no changes needed)
|
||||
|
||||
-- Michael Tokarev <mjt@tls.msk.ru> Fri, 23 May 2014 21:20:24 +0400
|
||||
|
||||
spice-protocol (0.12.6-1) unstable; urgency=low
|
||||
|
||||
* New upstream release
|
||||
* Bump Standards-Version to 3.9.4
|
||||
* Update VCS-* to use canonical URIs
|
||||
|
||||
-- Liang Guo <guoliang@debian.org> Wed, 17 Jul 2013 17:45:43 +0800
|
||||
|
||||
spice-protocol (0.12.5-2) unstable; urgency=low
|
||||
|
||||
* Upload to unstable
|
||||
|
||||
-- Liang Guo <guoliang@debian.org> Thu, 09 May 2013 21:06:35 +0800
|
||||
|
||||
spice-protocol (0.12.5-1) experimental; urgency=low
|
||||
|
||||
* New upstream release
|
||||
|
||||
-- Liang Guo <guoliang@debian.org> Thu, 11 Apr 2013 23:43:28 +0800
|
||||
|
||||
spice-protocol (0.12.3-1) experimental; urgency=low
|
||||
|
||||
* New upstream release
|
||||
|
||||
-- Liang Guo <guoliang@debian.org> Sun, 30 Dec 2012 22:53:53 +0800
|
||||
|
||||
spice-protocol (0.12.2-1) experimental; urgency=low
|
||||
|
||||
* New upstream release
|
||||
|
||||
-- Liang Guo <guoliang@debian.org> Wed, 26 Sep 2012 21:11:09 +0800
|
||||
|
||||
spice-protocol (0.12.0-1) experimental; urgency=low
|
||||
|
||||
* New upstream release
|
||||
* debian/control:
|
||||
- Update my e-mail address
|
||||
- Remove DMUA
|
||||
- Bump Standards-Version to 3.9.3
|
||||
|
||||
-- Liang Guo <guoliang@debian.org> Sun, 02 Sep 2012 09:27:34 +0800
|
||||
|
||||
spice-protocol (0.10.1-1) unstable; urgency=low
|
||||
|
||||
* New upstream release
|
||||
|
||||
-- Liang Guo <bluestonechina@gmail.com> Mon, 23 Jan 2012 11:07:19 +0800
|
||||
|
||||
spice-protocol (0.10.0-1) unstable; urgency=low
|
||||
|
||||
* New upstream release
|
||||
|
||||
-- Liang Guo <bluestonechina@gmail.com> Tue, 29 Nov 2011 12:09:29 +0800
|
||||
|
||||
spice-protocol (0.8.2-1) unstable; urgency=low
|
||||
|
||||
[ Liang Guo ]
|
||||
* New upstream release
|
||||
* Update Format field in debian/copyright
|
||||
|
||||
[ Aron Xu ]
|
||||
* debian/control: set DMUA.
|
||||
|
||||
-- Liang Guo <bluestonechina@gmail.com> Thu, 20 Oct 2011 10:21:30 +0800
|
||||
|
||||
spice-protocol (0.8.1-1) unstable; urgency=low
|
||||
|
||||
* New upstream release
|
||||
* Remove include_types_h_in_controller_port.patch, applied upstream
|
||||
|
||||
-- Liang Guo <bluestonechina@gmail.com> Mon, 18 Jul 2011 21:57:56 +0800
|
||||
|
||||
spice-protocol (0.8.0-2) unstable; urgency=low
|
||||
|
||||
* Add missing spice/types include in spice/controller_prot.h
|
||||
* Bump Standards-Version to 3.9.2, nothing to change
|
||||
* Update debian/copyright to compliant with DEP-5
|
||||
* Set Architecture to all
|
||||
|
||||
-- Liang Guo <bluestonechina@gmail.com> Sun, 03 Jul 2011 01:56:51 +0800
|
||||
|
||||
spice-protocol (0.8.0-1) unstable; urgency=low
|
||||
|
||||
* Initial release (Closes: #603697)
|
||||
|
||||
-- Liang Guo <bluestonechina@gmail.com> Sun, 10 Apr 2011 23:09:10 +0800
|
||||
24
debian/control
vendored
Normal file
24
debian/control
vendored
Normal file
@ -0,0 +1,24 @@
|
||||
Source: spice-protocol
|
||||
Priority: optional
|
||||
Maintainer: Debian QEMU Team <pkg-qemu-devel@lists.alioth.debian.org>
|
||||
Uploaders: Michael Tokarev <mjt@tls.msk.ru>
|
||||
Build-Depends: debhelper-compat (= 12), meson
|
||||
Standards-Version: 4.5.0
|
||||
Section: libs
|
||||
Homepage: https://www.spice-space.org/
|
||||
Vcs-Git: https://salsa.debian.org/qemu-team/spice-protocol.git
|
||||
Vcs-Browser: https://salsa.debian.org/qemu-team/spice-protocol
|
||||
|
||||
Package: libspice-protocol-dev
|
||||
Section: libdevel
|
||||
Architecture: all
|
||||
Multi-Arch: foreign
|
||||
Depends: ${misc:Depends}
|
||||
Description: SPICE protocol headers
|
||||
The Simple Protocol for Independent Computing Environments (SPICE)
|
||||
is a remote display system built for virtual environments which
|
||||
allows you to view a computing 'desktop' environment not only on
|
||||
the machine where it is running, but from anywhere on the Internet
|
||||
and from a wide variety of machine architectures.
|
||||
.
|
||||
This package provides headers defining protocols.
|
||||
69
debian/copyright
vendored
Normal file
69
debian/copyright
vendored
Normal file
@ -0,0 +1,69 @@
|
||||
Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
|
||||
Upstream-Name: spice-protocol
|
||||
Upstream-Contact: Alexander Larsson <alexl@redhat.com>,
|
||||
Alon Levy <alevy@redhat.com>,
|
||||
Arnon Gilboa <agilboa@agilboa.usersys.redhat.com>,
|
||||
Gerd Hoffmann <kraxel@redhat.com>,
|
||||
Izik Eidus <ieidus@redhat.com>,
|
||||
Yonit Halperin <yhalperi@redhat.com>
|
||||
Source: https://www.spice-space.org/download/releases/
|
||||
|
||||
Files: *
|
||||
Copyright: Copyright (C) 2009-2013 Red Hat, Inc
|
||||
License: BSD-3-clause
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are
|
||||
met:
|
||||
.
|
||||
\* Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
\* Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in
|
||||
the documentation and/or other materials provided with the
|
||||
distribution.
|
||||
\* Neither the name of the copyright holder nor the names of its
|
||||
contributors may be used to endorse or promote products derived
|
||||
from this software without specific prior written permission.
|
||||
.
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS "AS
|
||||
IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
||||
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
||||
PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
|
||||
Files: spice/macros.h
|
||||
debian/*
|
||||
Copyright: Copyright (C) 2009-2010 Red Hat, Inc
|
||||
Copyright (C) 2010 Liang Guo <bluestonechina@gmail.com>
|
||||
License: LGPL-2+
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License as
|
||||
published by the Free Software Foundation; either version 2 of
|
||||
the License, or (at your option) any later version.
|
||||
.
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
.
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
.
|
||||
This file is to a large extent based on gmacros.h from glib
|
||||
Which is LGPL and copyright:
|
||||
.
|
||||
Modified by the GLib Team and others 1997-2000. See the AUTHORS
|
||||
file for a list of people on the GLib Team. See the ChangeLog
|
||||
files for a list of changes. These files are distributed with
|
||||
GLib at ftp://ftp.gtk.org/pub/gtk/.
|
||||
.
|
||||
On Debian systems, the full text of the GNU General Public
|
||||
License version 2 can be found in the file
|
||||
'/usr/share/common-licenses/GPL-2'.
|
||||
2
debian/docs
vendored
Normal file
2
debian/docs
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
README.md
|
||||
CHANGELOG.md
|
||||
2
debian/gbp.conf
vendored
Normal file
2
debian/gbp.conf
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
[DEFAULT]
|
||||
pristine-tar = True
|
||||
13
debian/rules
vendored
Executable file
13
debian/rules
vendored
Executable file
@ -0,0 +1,13 @@
|
||||
#!/usr/bin/make -f
|
||||
# -*- makefile -*-
|
||||
# Uncomment this to turn on verbose mode.
|
||||
#export DH_VERBOSE=1
|
||||
|
||||
%:
|
||||
dh $@
|
||||
|
||||
# meson-generated spice-protocol.pc contains libdir= assignment
|
||||
# which is not used but causes lintian to emit error condition
|
||||
override_dh_auto_build:
|
||||
dh_auto_build
|
||||
sed -i '/^libdir=/D' obj-*/meson-private/spice-protocol.pc
|
||||
1
debian/source/format
vendored
Normal file
1
debian/source/format
vendored
Normal file
@ -0,0 +1 @@
|
||||
3.0 (quilt)
|
||||
176
debian/upstream/signing-key.asc
vendored
Normal file
176
debian/upstream/signing-key.asc
vendored
Normal file
@ -0,0 +1,176 @@
|
||||
-----BEGIN PGP PUBLIC KEY BLOCK-----
|
||||
|
||||
mQINBFa5yS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RKGNcQ+F/cTGytDbrIX3uPxN0SIqXoLVU8cIq2G7UtkJX0o++y8Tcs4/
|
||||
hZ+I4rNbudjie3Q1sHzbkGCg1of9t+xdowa9k75KZEU7bHHMYXXCzemV8zTkNLub
|
||||
vdKiAY8J9Vtc8OUCCoO7qjX4NsyqAXHjhsZbXd9Tut42Xrt3j6Qd0SnaPuePRhUv
|
||||
Ug8=
|
||||
=SvO/
|
||||
-----END PGP PUBLIC KEY BLOCK-----
|
||||
3
debian/watch
vendored
Normal file
3
debian/watch
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
version=4
|
||||
opts=pgpsigurlmangle=s/$/.sig/ \
|
||||
https://www.spice-space.org/download/releases/spice-protocol-(\d+\.\d*[02468]\.\d+)\.tar\.(bz2|xz)
|
||||
25
meson.build
Normal file
25
meson.build
Normal file
@ -0,0 +1,25 @@
|
||||
#
|
||||
# project definition
|
||||
#
|
||||
project('spice-protocol',
|
||||
version : '0.14.3',
|
||||
license : 'BSD',
|
||||
meson_version : '>= 0.41.0')
|
||||
|
||||
subdir('spice')
|
||||
|
||||
spice_protocol_dep = declare_dependency(include_directories : include_directories('.'))
|
||||
|
||||
#
|
||||
# spice-protocol.pc generation
|
||||
#
|
||||
datadir = get_option('datadir')
|
||||
pkgconfig_dir = join_paths(get_option('prefix'), datadir, 'pkgconfig')
|
||||
|
||||
pkgconfig = import('pkgconfig')
|
||||
pkgconfig.generate(name : meson.project_name(),
|
||||
description : 'SPICE protocol headers',
|
||||
version : meson.project_version(),
|
||||
subdirs : 'spice-1',
|
||||
install_dir : pkgconfig_dir,
|
||||
variables : 'datadir=@0@'.format(join_paths('${prefix}', datadir)))
|
||||
Binary file not shown.
@ -1 +0,0 @@
|
||||
d43b8c215eafc4cb0a95f2fed27da015721084fb
|
||||
207
spice-protocol.spec
Normal file
207
spice-protocol.spec
Normal file
@ -0,0 +1,207 @@
|
||||
Name: spice-protocol
|
||||
Version: 0.14.3
|
||||
Release: 1%{?dist}
|
||||
Summary: Spice protocol header files
|
||||
Group: Development/Libraries
|
||||
License: BSD
|
||||
URL: https://www.spice-space.org
|
||||
Source0: https://www.spice-space.org/download/releases/%{name}-%{version}.tar.xz
|
||||
BuildArch: noarch
|
||||
BuildRequires: meson gcc
|
||||
BuildRequires: mingw32-filesystem >= 95
|
||||
BuildRequires: mingw64-filesystem >= 95
|
||||
|
||||
%define desc Header files describing the spice protocol \
|
||||
and the para-virtual graphics card QXL.
|
||||
|
||||
%description
|
||||
%{desc}
|
||||
|
||||
%package -n mingw32-spice-protocol
|
||||
Summary: %{summary}
|
||||
Requires: mingw32-pkg-config
|
||||
|
||||
%description -n mingw32-spice-protocol
|
||||
%{desc}
|
||||
|
||||
%package -n mingw64-spice-protocol
|
||||
Summary: %{summary}
|
||||
Requires: mingw64-pkg-config
|
||||
|
||||
%description -n mingw64-spice-protocol
|
||||
%{desc}
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
|
||||
%build
|
||||
%meson
|
||||
%meson_build
|
||||
|
||||
%mingw_meson
|
||||
%mingw_ninja
|
||||
|
||||
|
||||
%install
|
||||
%meson_install
|
||||
export DESTDIR=%{buildroot}
|
||||
%mingw_ninja install
|
||||
|
||||
|
||||
%files
|
||||
%doc COPYING CHANGELOG.md
|
||||
%{_includedir}/spice-1
|
||||
%{_datadir}/pkgconfig/spice-protocol.pc
|
||||
|
||||
%files -n mingw32-spice-protocol
|
||||
%doc COPYING CHANGELOG.md
|
||||
%{mingw32_includedir}/spice-1
|
||||
%{mingw32_datadir}/pkgconfig/spice-protocol.pc
|
||||
|
||||
%files -n mingw64-spice-protocol
|
||||
%doc COPYING CHANGELOG.md
|
||||
%{mingw64_includedir}/spice-1
|
||||
%{mingw64_datadir}/pkgconfig/spice-protocol.pc
|
||||
|
||||
|
||||
%changelog
|
||||
* Fri Apr 12 2019 Victor Toso <victortoso@redhat.com> - 0.14.0-1
|
||||
- Update to 0.14.0 release
|
||||
|
||||
* Sun Feb 03 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.12.15-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
|
||||
|
||||
* Mon Jan 14 2019 Marc-André Lureau <marcandre.lureau@redhat.com> - 0.12.15-1
|
||||
- Update to 0.12.15 release
|
||||
|
||||
* Fri Jul 13 2018 Victor Toso <victortoso@redhat.com> - 0.12.14-2
|
||||
- Align QXLRam to 4 bytes to avoid compilers detect misaligned access
|
||||
Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1565766
|
||||
|
||||
* Thu Jun 07 2018 Christophe Fergeau <cfergeau@redhat.com> - 0.12.14-1
|
||||
- Update to 0.12.14 release
|
||||
|
||||
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.12.13-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
|
||||
|
||||
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.12.13-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
|
||||
|
||||
* Wed Jul 12 2017 Marc-André Lureau <marcandre.lureau@redhat.com> - 0.12.13-1
|
||||
- Update to 0.12.13 release
|
||||
|
||||
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.12.12-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
|
||||
|
||||
* Fri Aug 05 2016 Christophe Fergeau <cfergeau@redhat.com> - 0.12.12-1
|
||||
- Update to 0.12.12 release
|
||||
|
||||
* Fri Mar 11 2016 Marc-André Lureau <marcandre.lureau@redhat.com> - 0.12.11-1
|
||||
- Update to 0.12.11 release
|
||||
|
||||
* Fri Feb 05 2016 Fedora Release Engineering <releng@fedoraproject.org> - 0.12.10-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
|
||||
|
||||
* Thu Oct 01 2015 Christophe Fergeau <cfergeau@redhat.com> 0.12.10-1
|
||||
- Update to 0.12.10 - Add python scripts and .proto files used
|
||||
to generate spice-gtk/spice-server marshalling C code
|
||||
|
||||
* Wed Jul 29 2015 Christophe Fergeau <cfergeau@redhat.com> 0.12.9-1
|
||||
- Update to 0.12.9 - Fixes QEMU build failures when using 0.12.8 with
|
||||
spice-server 0.12.5
|
||||
|
||||
* Tue Jun 30 2015 Christophe Fergeau <cfergeau@redhat.com> 0.12.8-1
|
||||
- Update to 0.12.8
|
||||
|
||||
* Fri Jun 19 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.12.7-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
|
||||
|
||||
* Sun Jun 08 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.12.7-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
|
||||
|
||||
* Mon May 19 2014 Christophe Fergeau <cfergeau@redhat.com> 0.12.7-1
|
||||
- Update to 0.12.7
|
||||
|
||||
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.12.6-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
|
||||
|
||||
* Wed Jul 3 2013 Hans de Goede <hdegoede@redhat.com> - 0.12.6-1
|
||||
- Update to 0.12.6
|
||||
|
||||
* Thu Mar 7 2013 Hans de Goede <hdegoede@redhat.com> - 0.12.5-1
|
||||
- Update to 0.12.5
|
||||
|
||||
* Fri Feb 1 2013 Marc-André Lureau <marcandre.lureau@redhat.com> - 0.12.4-1
|
||||
- Update to 0.12.4
|
||||
|
||||
* Thu Dec 20 2012 Hans de Goede <hdegoede@redhat.com> - 0.12.3-1
|
||||
- Update to 0.12.3
|
||||
|
||||
* Fri Sep 28 2012 Hans de Goede <hdegoede@redhat.com> - 0.12.2-1
|
||||
- Update to 0.12.2
|
||||
|
||||
* Thu Sep 6 2012 Soren Sandmann <ssp@redhat.com> - 0.12.1-1
|
||||
- Add patch1 and patch2 to support capability bits
|
||||
|
||||
* Thu Sep 6 2012 Soren Sandmann <ssp@redhat.com> - 0.12.1-1
|
||||
- Update to 0.12.1
|
||||
|
||||
* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.10.1-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
|
||||
|
||||
* Mon Jan 16 2012 Hans de Goede <hdegoede@redhat.com> - 0.10.1-1
|
||||
- Update to 0.10.1
|
||||
|
||||
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.10.0-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
|
||||
|
||||
* Sun Nov 13 2011 Alon Levy <alevy@redhat.com> - 0.10.0-1
|
||||
- Update to 0.10.0
|
||||
|
||||
* Sun Oct 23 2011 Alon Levy <alevy@redhat.com> - 0.9.1-1
|
||||
- Update to 0.9.1
|
||||
|
||||
* Thu Aug 25 2011 Hans de Goede <hdegoede@redhat.com> - 0.9.0-1
|
||||
- Update to 0.9.0
|
||||
|
||||
* Mon Jul 25 2011 Marc-André Lureau <marcandre.lureau@redhat.com> - 0.8.1-2
|
||||
- Added spice-protocol-0.8.1-define-INLINE.patch
|
||||
|
||||
* Tue Jul 19 2011 Marc-André Lureau <marcandre.lureau@redhat.com> - 0.8.1-1
|
||||
- Update to 0.8.1
|
||||
|
||||
* Tue Mar 1 2011 Hans de Goede <hdegoede@redhat.com> - 0.8.0-1
|
||||
- Update to 0.8.0
|
||||
|
||||
* Fri Feb 11 2011 Hans de Goede <hdegoede@redhat.com> - 0.7.1-1
|
||||
- Update to 0.7.1
|
||||
|
||||
* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.7.0-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
|
||||
|
||||
* Wed Jan 12 2011 Hans de Goede <hdegoede@redhat.com> - 0.7.0-2
|
||||
- Update License tag (controller and foreign menu headers are LGPL)
|
||||
|
||||
* Fri Dec 17 2010 Hans de Goede <hdegoede@redhat.com> - 0.7.0-1
|
||||
- Update to 0.7.0
|
||||
|
||||
* Mon Oct 18 2010 Hans de Goede <hdegoede@redhat.com> - 0.6.3-1
|
||||
- Update to 0.6.3
|
||||
|
||||
* Thu Sep 30 2010 Gerd Hoffmann <kraxel@redhat.com> - 0.6.1-1
|
||||
- Update to 0.6.1.
|
||||
|
||||
* Tue Aug 31 2010 Alexander Larsson <alexl@redhat.com> - 0.6.0-1
|
||||
- Update to 0.6.0 (stable release)
|
||||
|
||||
* Tue Jul 20 2010 Alexander Larsson <alexl@redhat.com> - 0.5.3-1
|
||||
- Update to 0.5.3
|
||||
|
||||
* Mon Jul 12 2010 Gerd Hoffmann <kraxel@redhat.com> - 0.5.2-2
|
||||
- Fix license: It is BSD, not GPL.
|
||||
- Cleanup specfile, drop bits not needed any more with
|
||||
recent rpm versions (F13+).
|
||||
|
||||
* Fri Jul 9 2010 Gerd Hoffmann <kraxel@redhat.com> - 0.5.2-1
|
||||
- initial package.
|
||||
|
||||
Binary file not shown.
@ -1 +0,0 @@
|
||||
513f66ccd4d6e732ca4733a920abb3fe9480713d
|
||||
Binary file not shown.
@ -1 +0,0 @@
|
||||
3f1d5cdce8627db4a6a00bdf9febb5a73f5f79ac
|
||||
Binary file not shown.
@ -1 +0,0 @@
|
||||
27511d2e9b2c4fdde78c9300205d207fe4fb5a24
|
||||
Binary file not shown.
@ -1 +0,0 @@
|
||||
83c3ec93ddf7bb909a339d86f26e6c220759a3e4
|
||||
Binary file not shown.
@ -1 +0,0 @@
|
||||
cef698ed11e82bd09db4a90a16c750cb16f9f075
|
||||
Binary file not shown.
@ -1 +0,0 @@
|
||||
a54e39adb7c11481826e27fe81f4f2c29a049574
|
||||
Binary file not shown.
@ -1 +0,0 @@
|
||||
095ca5e1d3847a14a1e9246807bc5f43613f6e6e
|
||||
Binary file not shown.
@ -1 +0,0 @@
|
||||
4078a2d168aed3fb0c22fe536da35bf896cc64d7
|
||||
Binary file not shown.
@ -1 +0,0 @@
|
||||
c183f701df06efe5bf042da3dee56dee8e2753b9
|
||||
Binary file not shown.
@ -1 +0,0 @@
|
||||
bb9cf1c5e7551f0b7cbb1dbe06c4ffa3fc4ec11f
|
||||
Binary file not shown.
@ -1 +0,0 @@
|
||||
b7db9ff71ae823a57c9b36c08dd7e423c3546362
|
||||
Binary file not shown.
@ -1 +0,0 @@
|
||||
04b38b5f43df929f7935e8cc5c9b3b20994d5898
|
||||
Binary file not shown.
@ -1 +0,0 @@
|
||||
e148fb9f30cb14689b4490ae5bd0be4e7571cd04
|
||||
@ -1,16 +0,0 @@
|
||||
-----BEGIN PGP SIGNATURE-----
|
||||
|
||||
iQIzBAABCAAdFiEEIG07NS9WbzsOZXLpl9kSPeN6SE8FAl5jU9kACgkQl9kSPeN6
|
||||
SE+4ug/+LsOH+QKU7CM+e62foxhJFUUyQGXzenYgfsuqpf+zXb9AUEp1msBQHndJ
|
||||
+aQ4qefABMR7q2B2GV4nsiDD+oxQph9gqGL3IXHUc+Sv7gb0VXfq/Hg+AA8XqUK7
|
||||
6gFGvBT4uegmUXVv9QUZ8KhCr2va9zav1N0g+T0xrS2Bs5ftVWx/KW0zBW3Hndlc
|
||||
Fiwqzx6h8IzfEdNmtojHLQK0FLWngiL27YQNQfwZn2I0+x/WhZv8Gnfan+mwB+oB
|
||||
yMsS3MPBsAtpePKBGMxCgJ5y1B+8i0YF3kjLnUyTfUby/1WIyezma+DAhvtHK9Sy
|
||||
H3VAAuGdYDN9iAhbv/TtAF2ZpJlYf1UeTqQT7ioYr1kLMm8Rk/Zgc1zrZGEButNc
|
||||
qJwzyINquqLw22CZO6kPRmC/QLnRJvc3tZi2OWpXna6qWPd29uE2/5gZRl4Z4pxg
|
||||
knJuFedf2td/RMLPrkrkyDj44cqFL0LP30fhPYPsiyQb/LUBKrqgVP/1cTwD7l0Q
|
||||
G2h6vqm6J0UylYCR/NY0Wm3uicyRIGjUlFOiFl9g+JqZHPsWrBjS712eCvfh3Ylf
|
||||
K6jXUxYCYbzMd9OVBX9KueFCuqC3pk3j4Nw89Fghhfud5jrzDfzSBupTsGIXureG
|
||||
QKGioXVjvzEuujEhQtqBMKFU4/vaFYAOJErAxRmAbF1H/almD4Y=
|
||||
=ASKY
|
||||
-----END PGP SIGNATURE-----
|
||||
Binary file not shown.
@ -1 +0,0 @@
|
||||
9ad8d848d945eb073363c6cb98b7b494f5a6e087
|
||||
Binary file not shown.
@ -1 +0,0 @@
|
||||
00c8247aa2b965e2ebff95c6f8507636d08801f9
|
||||
Binary file not shown.
@ -1 +0,0 @@
|
||||
cc4bc9ab5f79873ab348c7cc0aeb0005b7def31f
|
||||
50
spice/barrier.h
Normal file
50
spice/barrier.h
Normal file
@ -0,0 +1,50 @@
|
||||
/* -*- Mode: C; tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- */
|
||||
/*
|
||||
Copyright (C) 2009 Red Hat, Inc.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are
|
||||
met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
* Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in
|
||||
the documentation and/or other materials provided with the
|
||||
distribution.
|
||||
* Neither the name of the copyright holder nor the names of its
|
||||
contributors may be used to endorse or promote products derived
|
||||
from this software without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS "AS
|
||||
IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
||||
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
||||
PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#ifndef _H_SPICE_BARRIER
|
||||
#define _H_SPICE_BARRIER
|
||||
|
||||
#ifdef __GNUC__
|
||||
|
||||
#define spice_mb() __sync_synchronize ()
|
||||
|
||||
#else
|
||||
|
||||
#ifdef _WIN64
|
||||
//__asm not supported on _WIN64, so use macro instead.
|
||||
#define spice_mb MemoryBarrier
|
||||
#else
|
||||
#define spice_mb() __asm {lock add [esp], 0}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
#endif /* _H_SPICE_BARRIER */
|
||||
39
spice/end-packed.h
Normal file
39
spice/end-packed.h
Normal file
@ -0,0 +1,39 @@
|
||||
/* -*- Mode: C; tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- */
|
||||
/*
|
||||
Copyright (C) 2009 Red Hat, Inc.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are
|
||||
met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
* Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in
|
||||
the documentation and/or other materials provided with the
|
||||
distribution.
|
||||
* Neither the name of the copyright holder nor the names of its
|
||||
contributors may be used to endorse or promote products derived
|
||||
from this software without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS "AS
|
||||
IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
||||
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
||||
PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
/* See start-packed.h for details */
|
||||
|
||||
#undef SPICE_ATTR_PACKED
|
||||
#undef SPICE_ATTR_ALIGNED
|
||||
|
||||
#if defined(__MINGW32__) || !defined(__GNUC__)
|
||||
#pragma pack(pop)
|
||||
#endif
|
||||
652
spice/enums.h
Normal file
652
spice/enums.h
Normal file
@ -0,0 +1,652 @@
|
||||
/* this is a file autogenerated by spice_codegen.py */
|
||||
/*
|
||||
Copyright (C) 2013 Red Hat, Inc.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are
|
||||
met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
* Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in
|
||||
the documentation and/or other materials provided with the
|
||||
distribution.
|
||||
* Neither the name of the copyright holder nor the names of its
|
||||
contributors may be used to endorse or promote products derived
|
||||
from this software without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS "AS
|
||||
IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
||||
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
||||
PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#ifndef _H_SPICE_ENUMS
|
||||
#define _H_SPICE_ENUMS
|
||||
|
||||
#include <spice/macros.h>
|
||||
|
||||
typedef enum SpiceLinkErr {
|
||||
SPICE_LINK_ERR_OK,
|
||||
SPICE_LINK_ERR_ERROR,
|
||||
SPICE_LINK_ERR_INVALID_MAGIC,
|
||||
SPICE_LINK_ERR_INVALID_DATA,
|
||||
SPICE_LINK_ERR_VERSION_MISMATCH,
|
||||
SPICE_LINK_ERR_NEED_SECURED,
|
||||
SPICE_LINK_ERR_NEED_UNSECURED,
|
||||
SPICE_LINK_ERR_PERMISSION_DENIED,
|
||||
SPICE_LINK_ERR_BAD_CONNECTION_ID,
|
||||
SPICE_LINK_ERR_CHANNEL_NOT_AVAILABLE,
|
||||
|
||||
SPICE_LINK_ERR_ENUM_END
|
||||
} SpiceLinkErr;
|
||||
|
||||
typedef enum SpiceWarnCode {
|
||||
SPICE_WARN_GENERAL,
|
||||
|
||||
SPICE_WARN_CODE_ENUM_END
|
||||
} SpiceWarnCode;
|
||||
|
||||
typedef enum SpiceInfoCode {
|
||||
SPICE_INFO_GENERAL,
|
||||
|
||||
SPICE_INFO_CODE_ENUM_END
|
||||
} SpiceInfoCode;
|
||||
|
||||
typedef enum SpiceMigrateFlags {
|
||||
SPICE_MIGRATE_NEED_FLUSH = (1 << 0),
|
||||
SPICE_MIGRATE_NEED_DATA_TRANSFER = (1 << 1),
|
||||
|
||||
SPICE_MIGRATE_FLAGS_MASK = 0x3
|
||||
} SpiceMigrateFlags;
|
||||
|
||||
typedef enum SpiceCompositeFlags {
|
||||
SPICE_COMPOSITE_OP0 = (1 << 0),
|
||||
SPICE_COMPOSITE_OP1 = (1 << 1),
|
||||
SPICE_COMPOSITE_OP2 = (1 << 2),
|
||||
SPICE_COMPOSITE_OP3 = (1 << 3),
|
||||
SPICE_COMPOSITE_OP4 = (1 << 4),
|
||||
SPICE_COMPOSITE_OP5 = (1 << 5),
|
||||
SPICE_COMPOSITE_OP6 = (1 << 6),
|
||||
SPICE_COMPOSITE_OP7 = (1 << 7),
|
||||
SPICE_COMPOSITE_SRC_FILTER0 = (1 << 8),
|
||||
SPICE_COMPOSITE_SRC_FILTER1 = (1 << 9),
|
||||
SPICE_COMPOSITE_SRC_FILTER2 = (1 << 10),
|
||||
SPICE_COMPOSITE_MASK_FILTER0 = (1 << 11),
|
||||
SPICE_COMPOSITE_MASK_FITLER1 = (1 << 12),
|
||||
SPICE_COMPOSITE_MASK_FILTER2 = (1 << 13),
|
||||
SPICE_COMPOSITE_SRC_REPEAT0 = (1 << 14),
|
||||
SPICE_COMPOSITE_SRC_REPEAT1 = (1 << 15),
|
||||
SPICE_COMPOSITE_MASK_REPEAT0 = (1 << 16),
|
||||
SPICE_COMPOSITE_MASK_REPEAT1 = (1 << 17),
|
||||
SPICE_COMPOSITE_COMPONENT_ALPHA = (1 << 18),
|
||||
SPICE_COMPOSITE_HAS_MASK = (1 << 19),
|
||||
SPICE_COMPOSITE_HAS_SRC_TRANSFORM = (1 << 20),
|
||||
SPICE_COMPOSITE_HAS_MASK_TRANSFORM = (1 << 21),
|
||||
SPICE_COMPOSITE_SOURCE_OPAQUE = (1 << 22),
|
||||
SPICE_COMPOSITE_MASK_OPAQUE = (1 << 23),
|
||||
SPICE_COMPOSITE_DEST_OPAQUE = (1 << 24),
|
||||
|
||||
SPICE_COMPOSITE_FLAGS_MASK = 0x1ffffff
|
||||
} SpiceCompositeFlags;
|
||||
|
||||
typedef enum SpiceNotifySeverity {
|
||||
SPICE_NOTIFY_SEVERITY_INFO,
|
||||
SPICE_NOTIFY_SEVERITY_WARN,
|
||||
SPICE_NOTIFY_SEVERITY_ERROR,
|
||||
|
||||
SPICE_NOTIFY_SEVERITY_ENUM_END
|
||||
} SpiceNotifySeverity;
|
||||
|
||||
typedef enum SpiceNotifyVisibility {
|
||||
SPICE_NOTIFY_VISIBILITY_LOW,
|
||||
SPICE_NOTIFY_VISIBILITY_MEDIUM,
|
||||
SPICE_NOTIFY_VISIBILITY_HIGH,
|
||||
|
||||
SPICE_NOTIFY_VISIBILITY_ENUM_END
|
||||
} SpiceNotifyVisibility;
|
||||
|
||||
typedef enum SpiceMouseMode {
|
||||
SPICE_MOUSE_MODE_SERVER = (1 << 0),
|
||||
SPICE_MOUSE_MODE_CLIENT = (1 << 1),
|
||||
|
||||
SPICE_MOUSE_MODE_MASK = 0x3
|
||||
} SpiceMouseMode;
|
||||
|
||||
typedef enum SpiceDataCompressionType {
|
||||
SPICE_DATA_COMPRESSION_TYPE_NONE,
|
||||
SPICE_DATA_COMPRESSION_TYPE_LZ4,
|
||||
|
||||
SPICE_DATA_COMPRESSION_TYPE_ENUM_END
|
||||
} SpiceDataCompressionType;
|
||||
|
||||
typedef enum SpiceClipType {
|
||||
SPICE_CLIP_TYPE_NONE,
|
||||
SPICE_CLIP_TYPE_RECTS,
|
||||
|
||||
SPICE_CLIP_TYPE_ENUM_END
|
||||
} SpiceClipType;
|
||||
|
||||
typedef enum SpicePathFlags {
|
||||
SPICE_PATH_BEGIN = (1 << 0),
|
||||
SPICE_PATH_END = (1 << 1),
|
||||
SPICE_PATH_CLOSE = (1 << 3),
|
||||
SPICE_PATH_BEZIER = (1 << 4),
|
||||
|
||||
SPICE_PATH_FLAGS_MASK = 0x1b
|
||||
} SpicePathFlags;
|
||||
|
||||
typedef enum SpiceVideoCodecType {
|
||||
SPICE_VIDEO_CODEC_TYPE_MJPEG = 1,
|
||||
SPICE_VIDEO_CODEC_TYPE_MJPEG_NVJPG,
|
||||
SPICE_VIDEO_CODEC_TYPE_MJPEG_VAAPI,
|
||||
SPICE_VIDEO_CODEC_TYPE_VP8,
|
||||
SPICE_VIDEO_CODEC_TYPE_H264,
|
||||
SPICE_VIDEO_CODEC_TYPE_H264_NVENC,
|
||||
SPICE_VIDEO_CODEC_TYPE_H264_AMF,
|
||||
SPICE_VIDEO_CODEC_TYPE_H264_QSV,
|
||||
SPICE_VIDEO_CODEC_TYPE_H264_VAAPI,
|
||||
SPICE_VIDEO_CODEC_TYPE_VP9,
|
||||
SPICE_VIDEO_CODEC_TYPE_H265,
|
||||
SPICE_VIDEO_CODEC_TYPE_H265_NVENC,
|
||||
SPICE_VIDEO_CODEC_TYPE_H265_AMF,
|
||||
SPICE_VIDEO_CODEC_TYPE_H265_QSV,
|
||||
SPICE_VIDEO_CODEC_TYPE_H265_VAAPI,
|
||||
SPICE_VIDEO_CODEC_TYPE_AV1_NVENC,
|
||||
SPICE_VIDEO_CODEC_TYPE_AV1_AMF,
|
||||
SPICE_VIDEO_CODEC_TYPE_AV1_QSV,
|
||||
SPICE_VIDEO_CODEC_TYPE_AV1_VAAPI,
|
||||
SPICE_VIDEO_CODEC_TYPE_ENUM_END
|
||||
} SpiceVideoCodecType;
|
||||
|
||||
typedef enum SpiceStreamFlags {
|
||||
SPICE_STREAM_FLAGS_TOP_DOWN = (1 << 0),
|
||||
|
||||
SPICE_STREAM_FLAGS_MASK = 0x1
|
||||
} SpiceStreamFlags;
|
||||
|
||||
typedef enum SpiceBrushType {
|
||||
SPICE_BRUSH_TYPE_NONE,
|
||||
SPICE_BRUSH_TYPE_SOLID,
|
||||
SPICE_BRUSH_TYPE_PATTERN,
|
||||
|
||||
SPICE_BRUSH_TYPE_ENUM_END
|
||||
} SpiceBrushType;
|
||||
|
||||
typedef enum SpiceMaskFlags {
|
||||
SPICE_MASK_FLAGS_INVERS = (1 << 0),
|
||||
|
||||
SPICE_MASK_FLAGS_MASK = 0x1
|
||||
} SpiceMaskFlags;
|
||||
|
||||
typedef enum SpiceImageType {
|
||||
SPICE_IMAGE_TYPE_BITMAP,
|
||||
SPICE_IMAGE_TYPE_QUIC,
|
||||
SPICE_IMAGE_TYPE_RESERVED,
|
||||
SPICE_IMAGE_TYPE_LZ_PLT = 100,
|
||||
SPICE_IMAGE_TYPE_LZ_RGB,
|
||||
SPICE_IMAGE_TYPE_GLZ_RGB,
|
||||
SPICE_IMAGE_TYPE_FROM_CACHE,
|
||||
SPICE_IMAGE_TYPE_SURFACE,
|
||||
SPICE_IMAGE_TYPE_JPEG,
|
||||
SPICE_IMAGE_TYPE_FROM_CACHE_LOSSLESS,
|
||||
SPICE_IMAGE_TYPE_ZLIB_GLZ_RGB,
|
||||
SPICE_IMAGE_TYPE_JPEG_ALPHA,
|
||||
SPICE_IMAGE_TYPE_LZ4,
|
||||
|
||||
SPICE_IMAGE_TYPE_ENUM_END
|
||||
} SpiceImageType;
|
||||
|
||||
typedef enum SpiceImageCompression {
|
||||
SPICE_IMAGE_COMPRESSION_INVALID,
|
||||
SPICE_IMAGE_COMPRESSION_OFF,
|
||||
SPICE_IMAGE_COMPRESSION_AUTO_GLZ,
|
||||
SPICE_IMAGE_COMPRESSION_AUTO_LZ,
|
||||
SPICE_IMAGE_COMPRESSION_QUIC,
|
||||
SPICE_IMAGE_COMPRESSION_GLZ,
|
||||
SPICE_IMAGE_COMPRESSION_LZ,
|
||||
SPICE_IMAGE_COMPRESSION_LZ4,
|
||||
|
||||
SPICE_IMAGE_COMPRESSION_ENUM_END
|
||||
} SpiceImageCompression;
|
||||
|
||||
typedef enum SpiceImageFlags {
|
||||
SPICE_IMAGE_FLAGS_CACHE_ME = (1 << 0),
|
||||
SPICE_IMAGE_FLAGS_HIGH_BITS_SET = (1 << 1),
|
||||
SPICE_IMAGE_FLAGS_CACHE_REPLACE_ME = (1 << 2),
|
||||
|
||||
SPICE_IMAGE_FLAGS_MASK = 0x7
|
||||
} SpiceImageFlags;
|
||||
|
||||
typedef enum SpiceBitmapFmt {
|
||||
SPICE_BITMAP_FMT_INVALID,
|
||||
SPICE_BITMAP_FMT_1BIT_LE,
|
||||
SPICE_BITMAP_FMT_1BIT_BE,
|
||||
SPICE_BITMAP_FMT_4BIT_LE,
|
||||
SPICE_BITMAP_FMT_4BIT_BE,
|
||||
SPICE_BITMAP_FMT_8BIT,
|
||||
SPICE_BITMAP_FMT_16BIT,
|
||||
SPICE_BITMAP_FMT_24BIT,
|
||||
SPICE_BITMAP_FMT_32BIT,
|
||||
SPICE_BITMAP_FMT_RGBA,
|
||||
SPICE_BITMAP_FMT_8BIT_A,
|
||||
|
||||
SPICE_BITMAP_FMT_ENUM_END
|
||||
} SpiceBitmapFmt;
|
||||
|
||||
typedef enum SpiceBitmapFlags {
|
||||
SPICE_BITMAP_FLAGS_PAL_CACHE_ME = (1 << 0),
|
||||
SPICE_BITMAP_FLAGS_PAL_FROM_CACHE = (1 << 1),
|
||||
SPICE_BITMAP_FLAGS_TOP_DOWN = (1 << 2),
|
||||
|
||||
SPICE_BITMAP_FLAGS_MASK = 0x7
|
||||
} SpiceBitmapFlags;
|
||||
|
||||
typedef enum SpiceJpegAlphaFlags {
|
||||
SPICE_JPEG_ALPHA_FLAGS_TOP_DOWN = (1 << 0),
|
||||
|
||||
SPICE_JPEG_ALPHA_FLAGS_MASK = 0x1
|
||||
} SpiceJpegAlphaFlags;
|
||||
|
||||
typedef enum SpiceImageScaleMode {
|
||||
SPICE_IMAGE_SCALE_MODE_INTERPOLATE,
|
||||
SPICE_IMAGE_SCALE_MODE_NEAREST,
|
||||
|
||||
SPICE_IMAGE_SCALE_MODE_ENUM_END
|
||||
} SpiceImageScaleMode;
|
||||
|
||||
typedef enum SpiceRopd {
|
||||
SPICE_ROPD_INVERS_SRC = (1 << 0),
|
||||
SPICE_ROPD_INVERS_BRUSH = (1 << 1),
|
||||
SPICE_ROPD_INVERS_DEST = (1 << 2),
|
||||
SPICE_ROPD_OP_PUT = (1 << 3),
|
||||
SPICE_ROPD_OP_OR = (1 << 4),
|
||||
SPICE_ROPD_OP_AND = (1 << 5),
|
||||
SPICE_ROPD_OP_XOR = (1 << 6),
|
||||
SPICE_ROPD_OP_BLACKNESS = (1 << 7),
|
||||
SPICE_ROPD_OP_WHITENESS = (1 << 8),
|
||||
SPICE_ROPD_OP_INVERS = (1 << 9),
|
||||
SPICE_ROPD_INVERS_RES = (1 << 10),
|
||||
|
||||
SPICE_ROPD_MASK = 0x7ff
|
||||
} SpiceRopd;
|
||||
|
||||
typedef enum SpiceLineFlags {
|
||||
SPICE_LINE_FLAGS_START_WITH_GAP = (1 << 2),
|
||||
SPICE_LINE_FLAGS_STYLED = (1 << 3),
|
||||
|
||||
SPICE_LINE_FLAGS_MASK = 0xc
|
||||
} SpiceLineFlags;
|
||||
|
||||
typedef enum SpiceStringFlags {
|
||||
SPICE_STRING_FLAGS_RASTER_A1 = (1 << 0),
|
||||
SPICE_STRING_FLAGS_RASTER_A4 = (1 << 1),
|
||||
SPICE_STRING_FLAGS_RASTER_A8 = (1 << 2),
|
||||
SPICE_STRING_FLAGS_RASTER_TOP_DOWN = (1 << 3),
|
||||
|
||||
SPICE_STRING_FLAGS_MASK = 0xf
|
||||
} SpiceStringFlags;
|
||||
|
||||
typedef enum SpiceSurfaceFlags {
|
||||
SPICE_SURFACE_FLAGS_PRIMARY = (1 << 0),
|
||||
SPICE_SURFACE_FLAGS_STREAMING_MODE = (1 << 1),
|
||||
|
||||
SPICE_SURFACE_FLAGS_MASK = 0x3
|
||||
} SpiceSurfaceFlags;
|
||||
|
||||
typedef enum SpiceSurfaceFmt {
|
||||
SPICE_SURFACE_FMT_INVALID,
|
||||
SPICE_SURFACE_FMT_1_A,
|
||||
SPICE_SURFACE_FMT_8_A = 8,
|
||||
SPICE_SURFACE_FMT_16_555 = 16,
|
||||
SPICE_SURFACE_FMT_32_xRGB = 32,
|
||||
SPICE_SURFACE_FMT_16_565 = 80,
|
||||
SPICE_SURFACE_FMT_32_ARGB = 96,
|
||||
|
||||
SPICE_SURFACE_FMT_ENUM_END
|
||||
} SpiceSurfaceFmt;
|
||||
|
||||
typedef enum SpiceAlphaFlags {
|
||||
SPICE_ALPHA_FLAGS_DEST_HAS_ALPHA = (1 << 0),
|
||||
SPICE_ALPHA_FLAGS_SRC_SURFACE_HAS_ALPHA = (1 << 1),
|
||||
|
||||
SPICE_ALPHA_FLAGS_MASK = 0x3
|
||||
} SpiceAlphaFlags;
|
||||
|
||||
typedef enum SpiceResourceType {
|
||||
SPICE_RES_TYPE_INVALID,
|
||||
SPICE_RES_TYPE_PIXMAP,
|
||||
|
||||
SPICE_RESOURCE_TYPE_ENUM_END
|
||||
} SpiceResourceType;
|
||||
|
||||
typedef enum SpiceGlScanoutFlags {
|
||||
SPICE_GL_SCANOUT_FLAGS_Y0TOP = (1 << 0),
|
||||
|
||||
SPICE_GL_SCANOUT_FLAGS_MASK = 0x1
|
||||
} SpiceGlScanoutFlags;
|
||||
|
||||
typedef enum SpiceKeyboardModifierFlags {
|
||||
SPICE_KEYBOARD_MODIFIER_FLAGS_SCROLL_LOCK = (1 << 0),
|
||||
SPICE_KEYBOARD_MODIFIER_FLAGS_NUM_LOCK = (1 << 1),
|
||||
SPICE_KEYBOARD_MODIFIER_FLAGS_CAPS_LOCK = (1 << 2),
|
||||
|
||||
SPICE_KEYBOARD_MODIFIER_FLAGS_MASK = 0x7
|
||||
} SpiceKeyboardModifierFlags;
|
||||
|
||||
typedef enum SpiceMouseButton {
|
||||
SPICE_MOUSE_BUTTON_INVALID,
|
||||
SPICE_MOUSE_BUTTON_LEFT,
|
||||
SPICE_MOUSE_BUTTON_MIDDLE,
|
||||
SPICE_MOUSE_BUTTON_RIGHT,
|
||||
SPICE_MOUSE_BUTTON_UP,
|
||||
SPICE_MOUSE_BUTTON_DOWN,
|
||||
SPICE_MOUSE_BUTTON_SIDE,
|
||||
SPICE_MOUSE_BUTTON_EXTRA,
|
||||
|
||||
SPICE_MOUSE_BUTTON_ENUM_END
|
||||
} SpiceMouseButton;
|
||||
|
||||
typedef enum SpiceMouseButtonMask {
|
||||
SPICE_MOUSE_BUTTON_MASK_LEFT = (1 << 0),
|
||||
SPICE_MOUSE_BUTTON_MASK_MIDDLE = (1 << 1),
|
||||
SPICE_MOUSE_BUTTON_MASK_RIGHT = (1 << 2),
|
||||
SPICE_MOUSE_BUTTON_MASK_UP = (1 << 3),
|
||||
SPICE_MOUSE_BUTTON_MASK_DOWN = (1 << 4),
|
||||
SPICE_MOUSE_BUTTON_MASK_SIDE = (1 << 5),
|
||||
SPICE_MOUSE_BUTTON_MASK_EXTRA = (1 << 6),
|
||||
|
||||
SPICE_MOUSE_BUTTON_MASK_MASK = 0x7F
|
||||
} SpiceMouseButtonMask;
|
||||
|
||||
typedef enum SpiceCursorType {
|
||||
SPICE_CURSOR_TYPE_ALPHA,
|
||||
SPICE_CURSOR_TYPE_MONO,
|
||||
SPICE_CURSOR_TYPE_COLOR4,
|
||||
SPICE_CURSOR_TYPE_COLOR8,
|
||||
SPICE_CURSOR_TYPE_COLOR16,
|
||||
SPICE_CURSOR_TYPE_COLOR24,
|
||||
SPICE_CURSOR_TYPE_COLOR32,
|
||||
|
||||
SPICE_CURSOR_TYPE_ENUM_END
|
||||
} SpiceCursorType;
|
||||
|
||||
typedef enum SpiceCursorFlags {
|
||||
SPICE_CURSOR_FLAGS_NONE = (1 << 0),
|
||||
SPICE_CURSOR_FLAGS_CACHE_ME = (1 << 1),
|
||||
SPICE_CURSOR_FLAGS_FROM_CACHE = (1 << 2),
|
||||
|
||||
SPICE_CURSOR_FLAGS_MASK = 0x7
|
||||
} SpiceCursorFlags;
|
||||
|
||||
typedef enum SpiceAudioDataMode {
|
||||
SPICE_AUDIO_DATA_MODE_INVALID,
|
||||
SPICE_AUDIO_DATA_MODE_RAW,
|
||||
SPICE_AUDIO_DATA_MODE_CELT_0_5_1 SPICE_GNUC_DEPRECATED,
|
||||
SPICE_AUDIO_DATA_MODE_OPUS,
|
||||
|
||||
SPICE_AUDIO_DATA_MODE_ENUM_END
|
||||
} SpiceAudioDataMode;
|
||||
|
||||
typedef enum SpiceAudioFmt {
|
||||
SPICE_AUDIO_FMT_INVALID,
|
||||
SPICE_AUDIO_FMT_S16,
|
||||
|
||||
SPICE_AUDIO_FMT_ENUM_END
|
||||
} SpiceAudioFmt;
|
||||
|
||||
typedef enum SpiceVscMessageType {
|
||||
SPICE_VSC_MESSAGE_TYPE_Init = 1,
|
||||
SPICE_VSC_MESSAGE_TYPE_Error,
|
||||
SPICE_VSC_MESSAGE_TYPE_ReaderAdd,
|
||||
SPICE_VSC_MESSAGE_TYPE_ReaderRemove,
|
||||
SPICE_VSC_MESSAGE_TYPE_ATR,
|
||||
SPICE_VSC_MESSAGE_TYPE_CardRemove,
|
||||
SPICE_VSC_MESSAGE_TYPE_APDU,
|
||||
SPICE_VSC_MESSAGE_TYPE_Flush,
|
||||
SPICE_VSC_MESSAGE_TYPE_FlushComplete,
|
||||
|
||||
SPICE_VSC_MESSAGE_TYPE_ENUM_END
|
||||
} SpiceVscMessageType;
|
||||
|
||||
enum {
|
||||
SPICE_CHANNEL_MAIN = 1,
|
||||
SPICE_CHANNEL_DISPLAY,
|
||||
SPICE_CHANNEL_INPUTS,
|
||||
SPICE_CHANNEL_CURSOR,
|
||||
SPICE_CHANNEL_PLAYBACK,
|
||||
SPICE_CHANNEL_RECORD,
|
||||
SPICE_CHANNEL_TUNNEL,
|
||||
SPICE_CHANNEL_SMARTCARD,
|
||||
SPICE_CHANNEL_USBREDIR,
|
||||
SPICE_CHANNEL_PORT,
|
||||
SPICE_CHANNEL_WEBDAV,
|
||||
|
||||
SPICE_END_CHANNEL
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_MSG_MIGRATE = 1,
|
||||
SPICE_MSG_MIGRATE_DATA,
|
||||
SPICE_MSG_SET_ACK,
|
||||
SPICE_MSG_PING,
|
||||
SPICE_MSG_WAIT_FOR_CHANNELS,
|
||||
SPICE_MSG_DISCONNECTING,
|
||||
SPICE_MSG_NOTIFY,
|
||||
SPICE_MSG_LIST,
|
||||
SPICE_MSG_BASE_LAST = 100,
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_MSGC_ACK_SYNC = 1,
|
||||
SPICE_MSGC_ACK,
|
||||
SPICE_MSGC_PONG,
|
||||
SPICE_MSGC_MIGRATE_FLUSH_MARK,
|
||||
SPICE_MSGC_MIGRATE_DATA,
|
||||
SPICE_MSGC_DISCONNECTING,
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_MSG_MAIN_MIGRATE_BEGIN = 101,
|
||||
SPICE_MSG_MAIN_MIGRATE_CANCEL,
|
||||
SPICE_MSG_MAIN_INIT,
|
||||
SPICE_MSG_MAIN_CHANNELS_LIST,
|
||||
SPICE_MSG_MAIN_MOUSE_MODE,
|
||||
SPICE_MSG_MAIN_MULTI_MEDIA_TIME,
|
||||
SPICE_MSG_MAIN_AGENT_CONNECTED,
|
||||
SPICE_MSG_MAIN_AGENT_DISCONNECTED,
|
||||
SPICE_MSG_MAIN_AGENT_DATA,
|
||||
SPICE_MSG_MAIN_AGENT_TOKEN,
|
||||
SPICE_MSG_MAIN_MIGRATE_SWITCH_HOST,
|
||||
SPICE_MSG_MAIN_MIGRATE_END,
|
||||
SPICE_MSG_MAIN_NAME,
|
||||
SPICE_MSG_MAIN_UUID,
|
||||
SPICE_MSG_MAIN_AGENT_CONNECTED_TOKENS,
|
||||
SPICE_MSG_MAIN_MIGRATE_BEGIN_SEAMLESS,
|
||||
SPICE_MSG_MAIN_MIGRATE_DST_SEAMLESS_ACK,
|
||||
SPICE_MSG_MAIN_MIGRATE_DST_SEAMLESS_NACK,
|
||||
|
||||
SPICE_MSG_END_MAIN
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_MSGC_MAIN_CLIENT_INFO = 101,
|
||||
SPICE_MSGC_MAIN_MIGRATE_CONNECTED,
|
||||
SPICE_MSGC_MAIN_MIGRATE_CONNECT_ERROR,
|
||||
SPICE_MSGC_MAIN_ATTACH_CHANNELS,
|
||||
SPICE_MSGC_MAIN_MOUSE_MODE_REQUEST,
|
||||
SPICE_MSGC_MAIN_AGENT_START,
|
||||
SPICE_MSGC_MAIN_AGENT_DATA,
|
||||
SPICE_MSGC_MAIN_AGENT_TOKEN,
|
||||
SPICE_MSGC_MAIN_MIGRATE_END,
|
||||
SPICE_MSGC_MAIN_MIGRATE_DST_DO_SEAMLESS,
|
||||
SPICE_MSGC_MAIN_MIGRATE_CONNECTED_SEAMLESS,
|
||||
SPICE_MSGC_MAIN_QUALITY_INDICATOR,
|
||||
|
||||
SPICE_MSGC_END_MAIN
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_MSG_DISPLAY_MODE = 101,
|
||||
SPICE_MSG_DISPLAY_MARK,
|
||||
SPICE_MSG_DISPLAY_RESET,
|
||||
SPICE_MSG_DISPLAY_COPY_BITS,
|
||||
SPICE_MSG_DISPLAY_INVAL_LIST,
|
||||
SPICE_MSG_DISPLAY_INVAL_ALL_PIXMAPS,
|
||||
SPICE_MSG_DISPLAY_INVAL_PALETTE,
|
||||
SPICE_MSG_DISPLAY_INVAL_ALL_PALETTES,
|
||||
SPICE_MSG_DISPLAY_STREAM_CREATE = 122,
|
||||
SPICE_MSG_DISPLAY_STREAM_DATA,
|
||||
SPICE_MSG_DISPLAY_STREAM_CLIP,
|
||||
SPICE_MSG_DISPLAY_STREAM_DESTROY,
|
||||
SPICE_MSG_DISPLAY_STREAM_DESTROY_ALL,
|
||||
SPICE_MSG_DISPLAY_DRAW_FILL = 302,
|
||||
SPICE_MSG_DISPLAY_DRAW_OPAQUE,
|
||||
SPICE_MSG_DISPLAY_DRAW_COPY,
|
||||
SPICE_MSG_DISPLAY_DRAW_BLEND,
|
||||
SPICE_MSG_DISPLAY_DRAW_BLACKNESS,
|
||||
SPICE_MSG_DISPLAY_DRAW_WHITENESS,
|
||||
SPICE_MSG_DISPLAY_DRAW_INVERS,
|
||||
SPICE_MSG_DISPLAY_DRAW_ROP3,
|
||||
SPICE_MSG_DISPLAY_DRAW_STROKE,
|
||||
SPICE_MSG_DISPLAY_DRAW_TEXT,
|
||||
SPICE_MSG_DISPLAY_DRAW_TRANSPARENT,
|
||||
SPICE_MSG_DISPLAY_DRAW_ALPHA_BLEND,
|
||||
SPICE_MSG_DISPLAY_SURFACE_CREATE,
|
||||
SPICE_MSG_DISPLAY_SURFACE_DESTROY,
|
||||
SPICE_MSG_DISPLAY_STREAM_DATA_SIZED,
|
||||
SPICE_MSG_DISPLAY_MONITORS_CONFIG,
|
||||
SPICE_MSG_DISPLAY_DRAW_COMPOSITE,
|
||||
SPICE_MSG_DISPLAY_STREAM_ACTIVATE_REPORT,
|
||||
SPICE_MSG_DISPLAY_GL_SCANOUT_UNIX,
|
||||
SPICE_MSG_DISPLAY_GL_DRAW,
|
||||
SPICE_MSG_DISPLAY_QUALITY_INDICATOR,
|
||||
|
||||
SPICE_MSG_END_DISPLAY
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_MSGC_DISPLAY_INIT = 101,
|
||||
SPICE_MSGC_DISPLAY_STREAM_REPORT,
|
||||
SPICE_MSGC_DISPLAY_PREFERRED_COMPRESSION,
|
||||
SPICE_MSGC_DISPLAY_GL_DRAW_DONE,
|
||||
SPICE_MSGC_DISPLAY_PREFERRED_VIDEO_CODEC_TYPE,
|
||||
|
||||
SPICE_MSGC_END_DISPLAY
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_MSG_INPUTS_INIT = 101,
|
||||
SPICE_MSG_INPUTS_KEY_MODIFIERS,
|
||||
SPICE_MSG_INPUTS_MOUSE_MOTION_ACK = 111,
|
||||
|
||||
SPICE_MSG_END_INPUTS
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_MSGC_INPUTS_KEY_DOWN = 101,
|
||||
SPICE_MSGC_INPUTS_KEY_UP,
|
||||
SPICE_MSGC_INPUTS_KEY_MODIFIERS,
|
||||
SPICE_MSGC_INPUTS_KEY_SCANCODE,
|
||||
SPICE_MSGC_INPUTS_MOUSE_MOTION = 111,
|
||||
SPICE_MSGC_INPUTS_MOUSE_POSITION,
|
||||
SPICE_MSGC_INPUTS_MOUSE_PRESS,
|
||||
SPICE_MSGC_INPUTS_MOUSE_RELEASE,
|
||||
|
||||
SPICE_MSGC_END_INPUTS
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_MSG_CURSOR_INIT = 101,
|
||||
SPICE_MSG_CURSOR_RESET,
|
||||
SPICE_MSG_CURSOR_SET,
|
||||
SPICE_MSG_CURSOR_MOVE,
|
||||
SPICE_MSG_CURSOR_HIDE,
|
||||
SPICE_MSG_CURSOR_TRAIL,
|
||||
SPICE_MSG_CURSOR_INVAL_ONE,
|
||||
SPICE_MSG_CURSOR_INVAL_ALL,
|
||||
|
||||
SPICE_MSG_END_CURSOR
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_MSG_PLAYBACK_DATA = 101,
|
||||
SPICE_MSG_PLAYBACK_MODE,
|
||||
SPICE_MSG_PLAYBACK_START,
|
||||
SPICE_MSG_PLAYBACK_STOP,
|
||||
SPICE_MSG_PLAYBACK_VOLUME,
|
||||
SPICE_MSG_PLAYBACK_MUTE,
|
||||
SPICE_MSG_PLAYBACK_LATENCY,
|
||||
|
||||
SPICE_MSG_END_PLAYBACK
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_MSG_RECORD_START = 101,
|
||||
SPICE_MSG_RECORD_STOP,
|
||||
SPICE_MSG_RECORD_VOLUME,
|
||||
SPICE_MSG_RECORD_MUTE,
|
||||
|
||||
SPICE_MSG_END_RECORD
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_MSGC_RECORD_DATA = 101,
|
||||
SPICE_MSGC_RECORD_MODE,
|
||||
SPICE_MSGC_RECORD_START_MARK,
|
||||
|
||||
SPICE_MSGC_END_RECORD
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_MSG_SMARTCARD_DATA = 101,
|
||||
|
||||
SPICE_MSG_END_SMARTCARD
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_MSGC_SMARTCARD_DATA = 101,
|
||||
SPICE_MSGC_SMARTCARD_HEADER = 101,
|
||||
SPICE_MSGC_SMARTCARD_ERROR = 101,
|
||||
SPICE_MSGC_SMARTCARD_ATR = 101,
|
||||
SPICE_MSGC_SMARTCARD_READER_ADD = 101,
|
||||
|
||||
SPICE_MSGC_END_SMARTCARD
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_MSG_SPICEVMC_DATA = 101,
|
||||
SPICE_MSG_SPICEVMC_COMPRESSED_DATA,
|
||||
|
||||
SPICE_MSG_END_SPICEVMC
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_MSGC_SPICEVMC_DATA = 101,
|
||||
SPICE_MSGC_SPICEVMC_COMPRESSED_DATA,
|
||||
|
||||
SPICE_MSGC_END_SPICEVMC
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_MSG_PORT_INIT = 201,
|
||||
SPICE_MSG_PORT_EVENT,
|
||||
|
||||
SPICE_MSG_END_PORT
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_MSGC_PORT_EVENT = 201,
|
||||
|
||||
SPICE_MSGC_END_PORT
|
||||
};
|
||||
|
||||
#endif /* _H_SPICE_ENUMS */
|
||||
136
spice/ipc_ring.h
Normal file
136
spice/ipc_ring.h
Normal file
@ -0,0 +1,136 @@
|
||||
/*
|
||||
Copyright (C) 2009 Red Hat, Inc.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are
|
||||
met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
* Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in
|
||||
the documentation and/or other materials provided with the
|
||||
distribution.
|
||||
* Neither the name of the copyright holder nor the names of its
|
||||
contributors may be used to endorse or promote products derived
|
||||
from this software without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS "AS
|
||||
IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
||||
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
||||
PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
|
||||
#ifndef _H_SPICE_RING
|
||||
#define _H_SPICE_RING
|
||||
|
||||
#include <spice/types.h>
|
||||
|
||||
#define _SPICE_MSB_MASK4(x) \
|
||||
(((x) & 0x8) ? 0x8 : \
|
||||
((x) & 0x4) ? 0x4 : \
|
||||
((x) & 0x2) ? 0x2 : \
|
||||
((x) & 0x1) ? 0x1 : 0)
|
||||
|
||||
#define _SPICE_MSB_MASK8(x) \
|
||||
(((x) & 0xf0) ? _SPICE_MSB_MASK4((x) >> 4) << 4 : _SPICE_MSB_MASK4(x))
|
||||
|
||||
#define _SPICE_MSB_MASK16(x) \
|
||||
(((x) & 0xff00) ? _SPICE_MSB_MASK8((x) >> 8) << 8 : _SPICE_MSB_MASK8(x))
|
||||
|
||||
#define _SPICE_MSB_MASK(x) \
|
||||
(((x) & 0xffff0000) ? _SPICE_MSB_MASK16((x) >> 16) << 16 : _SPICE_MSB_MASK16(x))
|
||||
|
||||
#define _SPICE_POWER2_ALIGN(x) _SPICE_MSB_MASK((x) * 2 - 1)
|
||||
|
||||
|
||||
#define _SPICE_TOSHIFT_4(x) \
|
||||
(((x) & 0x8) ? 3 : \
|
||||
((x) & 0x4) ? 2 : \
|
||||
((x) & 0x2) ? 1 : 0)
|
||||
|
||||
#define _SPICE_TOSHIFT_8(x) \
|
||||
(((x) & 0xf0) ? _SPICE_TOSHIFT_4((x) >> 4) + 4 : _SPICE_TOSHIFT_4(x))
|
||||
|
||||
#define _SPICE_TOSHIFT_16(x) \
|
||||
(((x) & 0xff00) ? _SPICE_TOSHIFT_8((x) >> 8) + 8 : _SPICE_TOSHIFT_8(x))
|
||||
|
||||
#define _SPICE_POWER2_TO_SHIFT(x) \
|
||||
(((x) & 0xffff0000) ? _SPICE_TOSHIFT_16((x) >> 16) + 16 : _SPICE_TOSHIFT_16(x))
|
||||
|
||||
|
||||
|
||||
#define SPICE_RING_DECLARE(name, el_type, size) \
|
||||
typedef struct SPICE_ATTR_PACKED name##_ring_el { \
|
||||
union { \
|
||||
el_type el; \
|
||||
uint8_t data[_SPICE_POWER2_ALIGN(sizeof(el_type))]; \
|
||||
} ; \
|
||||
} name##_ring_el; \
|
||||
\
|
||||
typedef struct SPICE_ATTR_PACKED name { \
|
||||
uint32_t num_items; \
|
||||
uint32_t prod; \
|
||||
uint32_t notify_on_prod; \
|
||||
uint32_t cons; \
|
||||
uint32_t notify_on_cons; \
|
||||
name##_ring_el items[_SPICE_POWER2_ALIGN(size)]; \
|
||||
} name;
|
||||
|
||||
|
||||
#define SPICE_RING_INIT(r) \
|
||||
(r)->num_items = sizeof((r)->items) >> \
|
||||
_SPICE_POWER2_TO_SHIFT(sizeof((r)->items[0])); \
|
||||
(r)->prod = (r)->cons = 0; \
|
||||
(r)->notify_on_prod = 1; \
|
||||
(r)->notify_on_cons = 0;
|
||||
|
||||
|
||||
#define SPICE_RING_INDEX_MASK(r) ((r)->num_items - 1)
|
||||
|
||||
#define SPICE_RING_IS_PACKED(r) (sizeof((r)->items[0]) == sizeof((r)->items[0]).el)
|
||||
|
||||
#define SPICE_RING_IS_EMPTY(r) ((r)->cons == (r)->prod)
|
||||
|
||||
#define SPICE_RING_IS_FULL(r) (((r)->prod - (r)->cons) == (r)->num_items)
|
||||
|
||||
#define SPICE_RING_PROD_ITEM(r) (&(r)->items[(r)->prod & SPICE_RING_INDEX_MASK(r)].el)
|
||||
|
||||
#define SPICE_RING_PROD_WAIT(r, wait) \
|
||||
if (((wait) = SPICE_RING_IS_FULL(r))) { \
|
||||
(r)->notify_on_cons = (r)->cons + 1; \
|
||||
spice_mb(); \
|
||||
(wait) = SPICE_RING_IS_FULL(r); \
|
||||
}
|
||||
|
||||
#define SPICE_RING_PUSH(r, notify) \
|
||||
(r)->prod++; \
|
||||
spice_mb(); \
|
||||
(notify) = (r)->prod == (r)->notify_on_prod;
|
||||
|
||||
|
||||
#define SPICE_RING_CONS_ITEM(r) (&(r)->items[(r)->cons & SPICE_RING_INDEX_MASK(r)].el)
|
||||
|
||||
#define SPICE_RING_CONS_WAIT(r, wait) \
|
||||
if (((wait) = SPICE_RING_IS_EMPTY(r))) { \
|
||||
(r)->notify_on_prod = (r)->prod + 1; \
|
||||
spice_mb(); \
|
||||
(wait) = SPICE_RING_IS_EMPTY(r); \
|
||||
}
|
||||
|
||||
#define SPICE_RING_POP(r, notify) \
|
||||
(r)->cons++; \
|
||||
spice_mb(); \
|
||||
(notify) = (r)->cons == (r)->notify_on_cons;
|
||||
|
||||
|
||||
|
||||
#endif /* _H_SPICE_RING */
|
||||
315
spice/macros.h
Normal file
315
spice/macros.h
Normal file
@ -0,0 +1,315 @@
|
||||
/* -*- Mode: C; c-basic-offset: 4; indent-tabs-mode: nil -*- */
|
||||
/*
|
||||
Copyright (C) 2010 Red Hat, Inc.
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with this library; if not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
/* This file is to a large extent based on gmacros.h from glib
|
||||
* Which is LGPL and copyright:
|
||||
*
|
||||
* Modified by the GLib Team and others 1997-2000. See the AUTHORS
|
||||
* file for a list of people on the GLib Team. See the ChangeLog
|
||||
* files for a list of changes. These files are distributed with
|
||||
* GLib at ftp://ftp.gtk.org/pub/gtk/.
|
||||
*/
|
||||
|
||||
#ifndef _H_SPICE_MACROS
|
||||
#define _H_SPICE_MACROS
|
||||
|
||||
/* We include stddef.h to get the system's definition of NULL */
|
||||
#include <stddef.h>
|
||||
|
||||
#include <spice/types.h>
|
||||
|
||||
#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 96)
|
||||
#define SPICE_GNUC_MALLOC __attribute__((__malloc__))
|
||||
#else
|
||||
#define SPICE_GNUC_MALLOC
|
||||
#endif
|
||||
|
||||
#ifndef __has_feature
|
||||
#define __has_feature(x) 0 /* Compatibility with non-clang compilers. */
|
||||
#endif
|
||||
|
||||
#if (!defined(__clang__) && ((__GNUC__ > 4) || (__GNUC__ == 4 && __GNUC_MINOR__ >= 3))) || \
|
||||
(defined(__clang__) && __has_feature(__alloc_size__))
|
||||
#define SPICE_GNUC_ALLOC_SIZE(x) __attribute__((__alloc_size__(x)))
|
||||
#define SPICE_GNUC_ALLOC_SIZE2(x,y) __attribute__((__alloc_size__(x,y)))
|
||||
#else
|
||||
#define SPICE_GNUC_ALLOC_SIZE(x)
|
||||
#define SPICE_GNUC_ALLOC_SIZE2(x,y)
|
||||
#endif
|
||||
|
||||
#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ > 4)
|
||||
#define SPICE_GNUC_PRINTF( format_idx, arg_idx ) __attribute__((__format__ (__printf__, format_idx, arg_idx)))
|
||||
#define SPICE_GNUC_NORETURN __attribute__((__noreturn__))
|
||||
#define SPICE_GNUC_UNUSED __attribute__((__unused__))
|
||||
#else /* !__GNUC__ */
|
||||
#define SPICE_GNUC_PRINTF( format_idx, arg_idx )
|
||||
#define SPICE_GNUC_NORETURN
|
||||
#define SPICE_GNUC_UNUSED
|
||||
#endif /* !__GNUC__ */
|
||||
|
||||
#ifdef G_DEPRECATED
|
||||
#define SPICE_GNUC_DEPRECATED G_DEPRECATED
|
||||
#elif __GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 1)
|
||||
#define SPICE_GNUC_DEPRECATED __attribute__((__deprecated__))
|
||||
#elif defined(_MSC_VER) && (_MSC_VER >= 1300)
|
||||
#define SPICE_GNUC_DEPRECATED __declspec(deprecated)
|
||||
#else
|
||||
#define SPICE_GNUC_DEPRECATED
|
||||
#endif
|
||||
|
||||
#if __GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 3)
|
||||
# define SPICE_GNUC_MAY_ALIAS __attribute__((may_alias))
|
||||
#else
|
||||
# define SPICE_GNUC_MAY_ALIAS
|
||||
#endif
|
||||
|
||||
#if __GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4)
|
||||
#define SPICE_GNUC_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
|
||||
#else
|
||||
#define SPICE_GNUC_WARN_UNUSED_RESULT
|
||||
#endif /* __GNUC__ */
|
||||
|
||||
|
||||
/* Guard C code in headers, while including them from C++ */
|
||||
#ifdef __cplusplus
|
||||
# define SPICE_BEGIN_DECLS extern "C" {
|
||||
# define SPICE_END_DECLS }
|
||||
#else
|
||||
# define SPICE_BEGIN_DECLS
|
||||
# define SPICE_END_DECLS
|
||||
#endif
|
||||
|
||||
#ifndef FALSE
|
||||
#define FALSE (0)
|
||||
#endif
|
||||
|
||||
#ifndef TRUE
|
||||
#define TRUE (!FALSE)
|
||||
#endif
|
||||
|
||||
#undef MAX
|
||||
#define MAX(a, b) (((a) > (b)) ? (a) : (b))
|
||||
|
||||
#undef MIN
|
||||
#define MIN(a, b) (((a) < (b)) ? (a) : (b))
|
||||
|
||||
#undef ABS
|
||||
#define ABS(a) (((a) < 0) ? -(a) : (a))
|
||||
|
||||
/* Count the number of elements in an array. The array must be defined
|
||||
* as such; using this with a dynamically allocated array will give
|
||||
* incorrect results.
|
||||
*/
|
||||
#define SPICE_N_ELEMENTS(arr) (sizeof (arr) / sizeof ((arr)[0]))
|
||||
|
||||
#define SPICE_ALIGN(a, size) (((a) + ((size) - 1)) & ~((size) - 1))
|
||||
|
||||
/* Provide convenience macros for handling structure
|
||||
* fields through their offsets.
|
||||
*/
|
||||
|
||||
#if defined(__GNUC__) && __GNUC__ >= 4
|
||||
# define SPICE_OFFSETOF(struct_type, member) \
|
||||
((long) offsetof (struct_type, member))
|
||||
#else
|
||||
# define SPICE_OFFSETOF(struct_type, member) \
|
||||
((long) ((uint8_t*) &((struct_type*) 0)->member))
|
||||
#endif
|
||||
|
||||
/* The SPICE_USE_SAFER_CONTAINEROF macro is used to avoid
|
||||
* compilation breakage with older spice-server releases which
|
||||
* triggered some errors without an additional patch.
|
||||
*/
|
||||
#if defined(__GNUC__) && defined(SPICE_USE_SAFER_CONTAINEROF) && \
|
||||
(__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
|
||||
#define SPICE_CONTAINEROF(ptr, struct_type, member) ({ \
|
||||
const typeof( ((struct_type *)0)->member ) *__mptr = (ptr); \
|
||||
((struct_type *)(void *)((uint8_t *)(__mptr) - SPICE_OFFSETOF(struct_type, member))); })
|
||||
#else
|
||||
#define SPICE_CONTAINEROF(ptr, struct_type, member) \
|
||||
((struct_type *)(void *)((uint8_t *)(ptr) - SPICE_OFFSETOF(struct_type, member)))
|
||||
#endif
|
||||
|
||||
#define SPICE_MEMBER_P(struct_p, struct_offset) \
|
||||
((gpointer) ((guint8*) (struct_p) + (glong) (struct_offset)))
|
||||
#define SPICE_MEMBER(member_type, struct_p, struct_offset) \
|
||||
(*(member_type*) SPICE_STRUCT_MEMBER_P ((struct_p), (struct_offset)))
|
||||
|
||||
/* Provide simple macro statement wrappers:
|
||||
* SPICE_STMT_START { statements; } SPICE_STMT_END;
|
||||
* This can be used as a single statement, like:
|
||||
* if (x) SPICE_STMT_START { ... } SPICE_STMT_END; else ...
|
||||
* This intentionally does not use compiler extensions like GCC's '({...})' to
|
||||
* avoid portability issue or side effects when compiled with different compilers.
|
||||
*/
|
||||
#if !(defined (SPICE_STMT_START) && defined (SPICE_STMT_END))
|
||||
# define SPICE_STMT_START do
|
||||
# define SPICE_STMT_END while (0)
|
||||
#endif
|
||||
|
||||
/*
|
||||
* The SPICE_LIKELY and SPICE_UNLIKELY macros let the programmer give hints to
|
||||
* the compiler about the expected result of an expression. Some compilers
|
||||
* can use this information for optimizations.
|
||||
*
|
||||
* The _SPICE_BOOLEAN_EXPR macro is intended to trigger a gcc warning when
|
||||
* putting assignments in g_return_if_fail ().
|
||||
*/
|
||||
#if defined(__GNUC__) && (__GNUC__ > 2) && defined(__OPTIMIZE__)
|
||||
#define _SPICE_BOOLEAN_EXPR(expr) \
|
||||
__extension__ ({ \
|
||||
int _g_boolean_var_; \
|
||||
if (expr) \
|
||||
_g_boolean_var_ = 1; \
|
||||
else \
|
||||
_g_boolean_var_ = 0; \
|
||||
_g_boolean_var_; \
|
||||
})
|
||||
#define SPICE_LIKELY(expr) (__builtin_expect (_SPICE_BOOLEAN_EXPR(expr), 1))
|
||||
#define SPICE_UNLIKELY(expr) (__builtin_expect (_SPICE_BOOLEAN_EXPR(expr), 0))
|
||||
#else
|
||||
#define SPICE_LIKELY(expr) (expr)
|
||||
#define SPICE_UNLIKELY(expr) (expr)
|
||||
#endif
|
||||
|
||||
#ifdef _MSC_VER
|
||||
#define SPICE_UINT64_CONSTANT(x) (x ## UI64)
|
||||
#define SPICE_INT64_CONSTANT(x) (x ## I64)
|
||||
#else
|
||||
#if LONG_MAX == 2147483647L
|
||||
#define SPICE_UINT64_CONSTANT(x) (x ## ULL)
|
||||
#define SPICE_INT64_CONSTANT(x) (x ## LL)
|
||||
#else
|
||||
#define SPICE_UINT64_CONSTANT(x) (x ## UL)
|
||||
#define SPICE_INT64_CONSTANT(x) (x ## L)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/* Little/Bit endian byte swapping */
|
||||
|
||||
#define SPICE_BYTESWAP16_CONSTANT(val) ((uint16_t) ( \
|
||||
(uint16_t) ((uint16_t) (val) >> 8) | \
|
||||
(uint16_t) ((uint16_t) (val) << 8)))
|
||||
|
||||
#define SPICE_BYTESWAP32_CONSTANT(val) ((uint32_t) ( \
|
||||
(((uint32_t) (val) & (uint32_t) 0x000000ffU) << 24) | \
|
||||
(((uint32_t) (val) & (uint32_t) 0x0000ff00U) << 8) | \
|
||||
(((uint32_t) (val) & (uint32_t) 0x00ff0000U) >> 8) | \
|
||||
(((uint32_t) (val) & (uint32_t) 0xff000000U) >> 24)))
|
||||
|
||||
#define SPICE_BYTESWAP64_CONSTANT(val) ((uint64_t) ( \
|
||||
(((uint64_t) (val) & \
|
||||
(uint64_t) SPICE_UINT64_CONSTANT(0x00000000000000ff)) << 56) | \
|
||||
(((uint64_t) (val) & \
|
||||
(uint64_t) SPICE_UINT64_CONSTANT(0x000000000000ff00)) << 40) | \
|
||||
(((uint64_t) (val) & \
|
||||
(uint64_t) SPICE_UINT64_CONSTANT(0x0000000000ff0000)) << 24) | \
|
||||
(((uint64_t) (val) & \
|
||||
(uint64_t) SPICE_UINT64_CONSTANT(0x00000000ff000000)) << 8) | \
|
||||
(((uint64_t) (val) & \
|
||||
(uint64_t) SPICE_UINT64_CONSTANT(0x000000ff00000000)) >> 8) | \
|
||||
(((uint64_t) (val) & \
|
||||
(uint64_t) SPICE_UINT64_CONSTANT(0x0000ff0000000000)) >> 24) | \
|
||||
(((uint64_t) (val) & \
|
||||
(uint64_t) SPICE_UINT64_CONSTANT(0x00ff000000000000)) >> 40) | \
|
||||
(((uint64_t) (val) & \
|
||||
(uint64_t) SPICE_UINT64_CONSTANT(0xff00000000000000)) >> 56)))
|
||||
|
||||
/* Arch specific stuff for speed
|
||||
*/
|
||||
#if defined (__GNUC__) && (__GNUC__ >= 4) && defined (__OPTIMIZE__)
|
||||
# define SPICE_BYTESWAP16(val) __builtin_bswap16(val)
|
||||
# define SPICE_BYTESWAP32(val) __builtin_bswap32(val)
|
||||
# define SPICE_BYTESWAP64(val) __builtin_bswap64(val)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SPICE_BYTESWAP16(val) _byteswap_ushort(val)
|
||||
# define SPICE_BYTESWAP32(val) _byteswap_ulong(val)
|
||||
# define SPICE_BYTESWAP64(val) _byteswap_uint64(val)
|
||||
#else /* generic */
|
||||
# define SPICE_BYTESWAP16(val) (SPICE_BYTESWAP16_CONSTANT (val))
|
||||
# define SPICE_BYTESWAP32(val) (SPICE_BYTESWAP32_CONSTANT (val))
|
||||
# define SPICE_BYTESWAP64(val) (SPICE_BYTESWAP64_CONSTANT (val))
|
||||
#endif /* generic */
|
||||
|
||||
|
||||
/* detect endianness */
|
||||
#undef SPICE_ENDIAN
|
||||
#define SPICE_ENDIAN_LITTLE 4321
|
||||
#define SPICE_ENDIAN_BIG 1234
|
||||
#define SPICE_ENDIAN_PDP 2143
|
||||
|
||||
/* gcc already defined these, use them */
|
||||
#if defined(__BYTE_ORDER__) && defined(__ORDER_LITTLE_ENDIAN__) \
|
||||
&& defined(__ORDER_BIG_ENDIAN__) && defined(__ORDER_PDP_ENDIAN__)
|
||||
# if __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SPICE_ENDIAN SPICE_ENDIAN_LITTLE
|
||||
# elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SPICE_ENDIAN SPICE_ENDIAN_BIG
|
||||
# elif __BYTE_ORDER__ == __ORDER_PDP_ENDIAN__
|
||||
# define SPICE_ENDIAN SPICE_ENDIAN_PDP
|
||||
# else
|
||||
# error __BYTE_ORDER__ not defined correctly
|
||||
# endif
|
||||
#endif
|
||||
|
||||
/* use suggestions at http://sourceforge.net/p/predef/wiki/Endianness/ */
|
||||
#ifndef SPICE_ENDIAN
|
||||
# if defined(__LITTLE_ENDIAN__) || defined(__ARMEL__) \
|
||||
|| defined(__THUMBEL__) || defined(__AARCH64EL__) \
|
||||
|| defined(_MIPSEL) || defined(__MIPSEL) || defined(__MIPSEL__) \
|
||||
|| defined(__amd64__) || defined(__x86_64__) || defined(__i386__) \
|
||||
|| defined(__e2k__)
|
||||
# define SPICE_ENDIAN SPICE_ENDIAN_LITTLE
|
||||
# endif
|
||||
# if defined(__BIG_ENDIAN__) || defined(__ARMEB__) \
|
||||
|| defined(__THUMBEB__) || defined(__AARCH64EB__) \
|
||||
|| defined(_MIPSEB) || defined(__MIPSEB) || defined(__MIPSEB__)
|
||||
# ifdef SPICE_ENDIAN
|
||||
# error Both little and big endian detected
|
||||
# endif
|
||||
# define SPICE_ENDIAN SPICE_ENDIAN_BIG
|
||||
# endif
|
||||
#endif
|
||||
|
||||
/* MS compiler */
|
||||
#if !defined(SPICE_ENDIAN) && defined(_MSC_VER)
|
||||
/* Windows support only little endian arm */
|
||||
# if defined(_M_IX86) || defined(_M_AMD64) || defined(_M_X64) \
|
||||
|| defined(_M_ARM)
|
||||
# define SPICE_ENDIAN SPICE_ENDIAN_LITTLE
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#if !defined(SPICE_ENDIAN)
|
||||
#error Unable to detect processor endianness
|
||||
#endif
|
||||
|
||||
#if SPICE_ENDIAN == SPICE_ENDIAN_PDP
|
||||
#error PDP endianness not supported by Spice
|
||||
#endif
|
||||
|
||||
|
||||
#if SPICE_ENDIAN == SPICE_ENDIAN_LITTLE
|
||||
#define SPICE_MAGIC_CONST(s) \
|
||||
((uint32_t)((s[0]&0xffu)|((s[1]&0xffu)<<8)|((s[2]&0xffu)<<16)|((s[3]&0xffu)<<24)))
|
||||
#else
|
||||
#define SPICE_MAGIC_CONST(s) \
|
||||
((uint32_t)((s[3]&0xffu)|((s[2]&0xffu)<<8)|((s[1]&0xffu)<<16)|((s[0]&0xffu)<<24)))
|
||||
#endif
|
||||
|
||||
#endif /* _H_SPICE_MACROS */
|
||||
18
spice/meson.build
Normal file
18
spice/meson.build
Normal file
@ -0,0 +1,18 @@
|
||||
spice_protocol_headers = [
|
||||
'barrier.h',
|
||||
'end-packed.h',
|
||||
'enums.h',
|
||||
'ipc_ring.h',
|
||||
'macros.h',
|
||||
'protocol.h',
|
||||
'qxl_dev.h',
|
||||
'qxl_windows.h',
|
||||
'start-packed.h',
|
||||
'stats.h',
|
||||
'types.h',
|
||||
'vd_agent.h',
|
||||
'stream-device.h',
|
||||
]
|
||||
|
||||
install_headers(spice_protocol_headers,
|
||||
subdir : join_paths('spice-1', 'spice'))
|
||||
185
spice/protocol.h
Normal file
185
spice/protocol.h
Normal file
@ -0,0 +1,185 @@
|
||||
/*
|
||||
Copyright (C) 2009 Red Hat, Inc.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are
|
||||
met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
* Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in
|
||||
the documentation and/or other materials provided with the
|
||||
distribution.
|
||||
* Neither the name of the copyright holder nor the names of its
|
||||
contributors may be used to endorse or promote products derived
|
||||
from this software without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS "AS
|
||||
IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
||||
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
||||
PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#ifndef _H_SPICE_PROTOCOL
|
||||
#define _H_SPICE_PROTOCOL
|
||||
|
||||
#include <spice/types.h>
|
||||
#include <spice/enums.h>
|
||||
#include <spice/macros.h>
|
||||
#include <spice/start-packed.h>
|
||||
|
||||
#define SPICE_MAGIC SPICE_MAGIC_CONST("REDQ")
|
||||
#define SPICE_VERSION_MAJOR 2
|
||||
#define SPICE_VERSION_MINOR 2
|
||||
|
||||
// Encryption & Ticketing Parameters
|
||||
#define SPICE_MAX_PASSWORD_LENGTH 60
|
||||
#define SPICE_TICKET_KEY_PAIR_LENGTH 1024
|
||||
#define SPICE_TICKET_PUBKEY_BYTES (SPICE_TICKET_KEY_PAIR_LENGTH / 8 + 34)
|
||||
|
||||
/*
|
||||
* This is the maximum number of streams possible.
|
||||
* IDs will be in the interval [0, SPICE_MAX_NUM_STREAMS).
|
||||
*/
|
||||
#define SPICE_MAX_NUM_STREAMS 64
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED SpiceLinkHeader {
|
||||
uint32_t magic;
|
||||
uint32_t major_version;
|
||||
uint32_t minor_version;
|
||||
uint32_t size;
|
||||
} SpiceLinkHeader;
|
||||
|
||||
enum {
|
||||
SPICE_COMMON_CAP_PROTOCOL_AUTH_SELECTION,
|
||||
SPICE_COMMON_CAP_AUTH_SPICE,
|
||||
SPICE_COMMON_CAP_AUTH_SASL,
|
||||
SPICE_COMMON_CAP_MINI_HEADER,
|
||||
};
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED SpiceLinkMess {
|
||||
uint32_t connection_id;
|
||||
uint8_t channel_type;
|
||||
uint8_t channel_id;
|
||||
uint32_t num_common_caps;
|
||||
uint32_t num_channel_caps;
|
||||
uint32_t caps_offset;
|
||||
} SpiceLinkMess;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED SpiceLinkReply {
|
||||
uint32_t error;
|
||||
uint8_t pub_key[SPICE_TICKET_PUBKEY_BYTES];
|
||||
uint32_t num_common_caps;
|
||||
uint32_t num_channel_caps;
|
||||
uint32_t caps_offset;
|
||||
} SpiceLinkReply;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED SpiceLinkEncryptedTicket {
|
||||
uint8_t encrypted_data[SPICE_TICKET_KEY_PAIR_LENGTH / 8];
|
||||
} SpiceLinkEncryptedTicket;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED SpiceLinkAuthMechanism {
|
||||
uint32_t auth_mechanism;
|
||||
} SpiceLinkAuthMechanism;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED SpiceDataHeader {
|
||||
uint64_t serial;
|
||||
uint16_t type;
|
||||
uint32_t size;
|
||||
uint32_t sub_list; //offset to SpiceSubMessageList[]
|
||||
} SpiceDataHeader;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED SpiceMiniDataHeader {
|
||||
uint16_t type;
|
||||
uint32_t size;
|
||||
} SpiceMiniDataHeader;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED SpiceSubMessage {
|
||||
uint16_t type;
|
||||
uint32_t size;
|
||||
} SpiceSubMessage;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED SpiceSubMessageList {
|
||||
uint16_t size;
|
||||
uint32_t sub_messages[0]; //offsets to SpicedSubMessage
|
||||
} SpiceSubMessageList;
|
||||
|
||||
#define SPICE_INPUT_MOTION_ACK_BUNCH 4
|
||||
|
||||
enum {
|
||||
SPICE_PLAYBACK_CAP_CELT_0_5_1,
|
||||
SPICE_PLAYBACK_CAP_VOLUME,
|
||||
SPICE_PLAYBACK_CAP_LATENCY,
|
||||
SPICE_PLAYBACK_CAP_OPUS,
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_RECORD_CAP_CELT_0_5_1,
|
||||
SPICE_RECORD_CAP_VOLUME,
|
||||
SPICE_RECORD_CAP_OPUS,
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_MAIN_CAP_SEMI_SEAMLESS_MIGRATE,
|
||||
SPICE_MAIN_CAP_NAME_AND_UUID,
|
||||
SPICE_MAIN_CAP_AGENT_CONNECTED_TOKENS,
|
||||
SPICE_MAIN_CAP_SEAMLESS_MIGRATE,
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_DISPLAY_CAP_SIZED_STREAM,
|
||||
SPICE_DISPLAY_CAP_MONITORS_CONFIG,
|
||||
SPICE_DISPLAY_CAP_COMPOSITE,
|
||||
SPICE_DISPLAY_CAP_A8_SURFACE,
|
||||
SPICE_DISPLAY_CAP_STREAM_REPORT,
|
||||
SPICE_DISPLAY_CAP_LZ4_COMPRESSION,
|
||||
SPICE_DISPLAY_CAP_PREF_COMPRESSION,
|
||||
SPICE_DISPLAY_CAP_GL_SCANOUT,
|
||||
SPICE_DISPLAY_CAP_MULTI_CODEC,
|
||||
SPICE_DISPLAY_CAP_CODEC_MJPEG,
|
||||
SPICE_DISPLAY_CAP_CODEC_MJPEG_NVJPG,
|
||||
SPICE_DISPLAY_CAP_CODEC_MJPEG_VAAPI,
|
||||
SPICE_DISPLAY_CAP_CODEC_VP8,
|
||||
SPICE_DISPLAY_CAP_CODEC_H264,
|
||||
SPICE_DISPLAY_CAP_CODEC_H264_NVENC,
|
||||
SPICE_DISPLAY_CAP_CODEC_H264_AMF,
|
||||
SPICE_DISPLAY_CAP_CODEC_H264_QSV,
|
||||
SPICE_DISPLAY_CAP_CODEC_H264_VAAPI,
|
||||
SPICE_DISPLAY_CAP_PREF_VIDEO_CODEC_TYPE,
|
||||
SPICE_DISPLAY_CAP_CODEC_VP9,
|
||||
SPICE_DISPLAY_CAP_CODEC_H265,
|
||||
SPICE_DISPLAY_CAP_CODEC_H265_NVENC,
|
||||
SPICE_DISPLAY_CAP_CODEC_H265_AMF,
|
||||
SPICE_DISPLAY_CAP_CODEC_H265_QSV,
|
||||
SPICE_DISPLAY_CAP_CODEC_H265_VAAPI,
|
||||
SPICE_DISPLAY_CAP_CODEC_AV1_NVENC,
|
||||
SPICE_DISPLAY_CAP_CODEC_AV1_AMF,
|
||||
SPICE_DISPLAY_CAP_CODEC_AV1_QSV,
|
||||
SPICE_DISPLAY_CAP_CODEC_AV1_VAAPI,
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_INPUTS_CAP_KEY_SCANCODE,
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_SPICEVMC_CAP_DATA_COMPRESS_LZ4,
|
||||
};
|
||||
|
||||
enum {
|
||||
SPICE_PORT_EVENT_OPENED,
|
||||
SPICE_PORT_EVENT_CLOSED,
|
||||
SPICE_PORT_EVENT_BREAK,
|
||||
};
|
||||
|
||||
#include <spice/end-packed.h>
|
||||
|
||||
#endif /* _H_SPICE_PROTOCOL */
|
||||
785
spice/qxl_dev.h
Normal file
785
spice/qxl_dev.h
Normal file
@ -0,0 +1,785 @@
|
||||
/*
|
||||
Copyright (C) 2009 Red Hat, Inc.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are
|
||||
met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
* Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in
|
||||
the documentation and/or other materials provided with the
|
||||
distribution.
|
||||
* Neither the name of the copyright holder nor the names of its
|
||||
contributors may be used to endorse or promote products derived
|
||||
from this software without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS "AS
|
||||
IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
||||
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
||||
PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
|
||||
#ifndef _H_QXL_DEV
|
||||
#define _H_QXL_DEV
|
||||
|
||||
#include <spice/types.h>
|
||||
#include <spice/barrier.h>
|
||||
#include <spice/ipc_ring.h>
|
||||
#include <spice/enums.h>
|
||||
#include <spice/macros.h>
|
||||
|
||||
#include <spice/start-packed.h>
|
||||
|
||||
#define REDHAT_PCI_VENDOR_ID 0x1b36
|
||||
|
||||
/* 0x100-0x11f reserved for spice, 0x1ff used for unstable work */
|
||||
#define QXL_DEVICE_ID_STABLE 0x0100
|
||||
|
||||
enum {
|
||||
QXL_REVISION_STABLE_V04=0x01,
|
||||
QXL_REVISION_STABLE_V06=0x02,
|
||||
QXL_REVISION_STABLE_V10=0x03,
|
||||
QXL_REVISION_STABLE_V12=0x04,
|
||||
};
|
||||
|
||||
#define QXL_DEVICE_ID_DEVEL 0x01ff
|
||||
#define QXL_REVISION_DEVEL 0x01
|
||||
|
||||
#define QXL_ROM_MAGIC SPICE_MAGIC_CONST("QXRO")
|
||||
#define QXL_RAM_MAGIC SPICE_MAGIC_CONST("QXRA")
|
||||
|
||||
enum {
|
||||
QXL_RAM_RANGE_INDEX,
|
||||
QXL_VRAM_RANGE_INDEX,
|
||||
QXL_ROM_RANGE_INDEX,
|
||||
QXL_IO_RANGE_INDEX,
|
||||
|
||||
QXL_PCI_RANGES
|
||||
};
|
||||
|
||||
/* qxl-1 compat: append only */
|
||||
enum {
|
||||
QXL_IO_NOTIFY_CMD,
|
||||
QXL_IO_NOTIFY_CURSOR,
|
||||
QXL_IO_UPDATE_AREA,
|
||||
QXL_IO_UPDATE_IRQ,
|
||||
QXL_IO_NOTIFY_OOM,
|
||||
QXL_IO_RESET,
|
||||
QXL_IO_SET_MODE, /* qxl-1 */
|
||||
QXL_IO_LOG,
|
||||
/* appended for qxl-2 */
|
||||
QXL_IO_MEMSLOT_ADD,
|
||||
QXL_IO_MEMSLOT_DEL,
|
||||
QXL_IO_DETACH_PRIMARY,
|
||||
QXL_IO_ATTACH_PRIMARY,
|
||||
QXL_IO_CREATE_PRIMARY,
|
||||
QXL_IO_DESTROY_PRIMARY,
|
||||
QXL_IO_DESTROY_SURFACE_WAIT,
|
||||
QXL_IO_DESTROY_ALL_SURFACES,
|
||||
/* appended for qxl-3 */
|
||||
QXL_IO_UPDATE_AREA_ASYNC,
|
||||
QXL_IO_MEMSLOT_ADD_ASYNC,
|
||||
QXL_IO_CREATE_PRIMARY_ASYNC,
|
||||
QXL_IO_DESTROY_PRIMARY_ASYNC,
|
||||
QXL_IO_DESTROY_SURFACE_ASYNC,
|
||||
QXL_IO_DESTROY_ALL_SURFACES_ASYNC,
|
||||
QXL_IO_FLUSH_SURFACES_ASYNC,
|
||||
QXL_IO_FLUSH_RELEASE,
|
||||
/* appended for qxl-4 */
|
||||
QXL_IO_MONITORS_CONFIG_ASYNC,
|
||||
|
||||
QXL_IO_RANGE_SIZE
|
||||
};
|
||||
|
||||
typedef uint64_t QXLPHYSICAL;
|
||||
typedef int32_t QXLFIXED; //fixed 28.4
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLPointFix {
|
||||
QXLFIXED x;
|
||||
QXLFIXED y;
|
||||
} QXLPointFix;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLPoint {
|
||||
int32_t x;
|
||||
int32_t y;
|
||||
} QXLPoint;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLPoint16 {
|
||||
int16_t x;
|
||||
int16_t y;
|
||||
} QXLPoint16;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLRect {
|
||||
int32_t top;
|
||||
int32_t left;
|
||||
int32_t bottom;
|
||||
int32_t right;
|
||||
} QXLRect;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLURect {
|
||||
uint32_t top;
|
||||
uint32_t left;
|
||||
uint32_t bottom;
|
||||
uint32_t right;
|
||||
} QXLURect;
|
||||
|
||||
/* qxl-1 compat: append only */
|
||||
typedef struct SPICE_ATTR_PACKED QXLRom {
|
||||
uint32_t magic;
|
||||
uint32_t id;
|
||||
uint32_t update_id;
|
||||
uint32_t compression_level;
|
||||
uint32_t log_level;
|
||||
uint32_t mode; /* qxl-1 */
|
||||
uint32_t modes_offset;
|
||||
uint32_t num_pages;
|
||||
uint32_t pages_offset; /* qxl-1 */
|
||||
uint32_t draw_area_offset; /* qxl-1 */
|
||||
uint32_t surface0_area_size; /* qxl-1 name: draw_area_size */
|
||||
uint32_t ram_header_offset;
|
||||
uint32_t mm_clock;
|
||||
/* appended for qxl-2 */
|
||||
uint32_t n_surfaces;
|
||||
uint64_t flags;
|
||||
uint8_t slots_start;
|
||||
uint8_t slots_end;
|
||||
uint8_t slot_gen_bits;
|
||||
uint8_t slot_id_bits;
|
||||
uint8_t slot_generation;
|
||||
/* appended for qxl-4 */
|
||||
uint8_t client_present;
|
||||
uint8_t client_capabilities[58];
|
||||
uint32_t client_monitors_config_crc;
|
||||
struct {
|
||||
uint16_t count;
|
||||
uint16_t padding;
|
||||
QXLURect heads[64];
|
||||
} client_monitors_config;
|
||||
} QXLRom;
|
||||
|
||||
#define CLIENT_MONITORS_CONFIG_CRC32_POLY 0xedb88320
|
||||
|
||||
/* qxl-1 compat: fixed */
|
||||
typedef struct SPICE_ATTR_PACKED QXLMode {
|
||||
uint32_t id;
|
||||
uint32_t x_res;
|
||||
uint32_t y_res;
|
||||
uint32_t bits;
|
||||
uint32_t stride;
|
||||
uint32_t x_mili;
|
||||
uint32_t y_mili;
|
||||
uint32_t orientation;
|
||||
} QXLMode;
|
||||
|
||||
/* qxl-1 compat: fixed */
|
||||
typedef struct SPICE_ATTR_PACKED QXLModes {
|
||||
uint32_t n_modes;
|
||||
QXLMode modes[0];
|
||||
} QXLModes;
|
||||
|
||||
/* qxl-1 compat: append only */
|
||||
typedef enum QXLCmdType {
|
||||
QXL_CMD_NOP,
|
||||
QXL_CMD_DRAW,
|
||||
QXL_CMD_UPDATE,
|
||||
QXL_CMD_CURSOR,
|
||||
QXL_CMD_MESSAGE,
|
||||
QXL_CMD_SURFACE,
|
||||
} QXLCmdType;
|
||||
|
||||
/* qxl-1 compat: fixed */
|
||||
typedef struct SPICE_ATTR_PACKED QXLCommand {
|
||||
QXLPHYSICAL data;
|
||||
uint32_t type;
|
||||
uint32_t padding;
|
||||
} QXLCommand;
|
||||
|
||||
#define QXL_COMMAND_FLAG_COMPAT (1<<0)
|
||||
#define QXL_COMMAND_FLAG_COMPAT_16BPP (2<<0)
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLCommandExt {
|
||||
QXLCommand cmd;
|
||||
uint32_t group_id;
|
||||
uint32_t flags;
|
||||
} QXLCommandExt;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLMemSlot {
|
||||
uint64_t mem_start;
|
||||
uint64_t mem_end;
|
||||
} QXLMemSlot;
|
||||
|
||||
#define QXL_SURF_TYPE_PRIMARY 0
|
||||
|
||||
#define QXL_SURF_FLAG_KEEP_DATA (1 << 0)
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLSurfaceCreate {
|
||||
uint32_t width;
|
||||
uint32_t height;
|
||||
int32_t stride;
|
||||
uint32_t format;
|
||||
uint32_t position;
|
||||
uint32_t mouse_mode;
|
||||
uint32_t flags;
|
||||
uint32_t type;
|
||||
QXLPHYSICAL mem;
|
||||
} QXLSurfaceCreate;
|
||||
|
||||
#define QXL_COMMAND_RING_SIZE 32
|
||||
#define QXL_CURSOR_RING_SIZE 32
|
||||
#define QXL_RELEASE_RING_SIZE 8
|
||||
|
||||
SPICE_RING_DECLARE(QXLCommandRing, QXLCommand, QXL_COMMAND_RING_SIZE);
|
||||
SPICE_RING_DECLARE(QXLCursorRing, QXLCommand, QXL_CURSOR_RING_SIZE);
|
||||
|
||||
SPICE_RING_DECLARE(QXLReleaseRing, uint64_t, QXL_RELEASE_RING_SIZE);
|
||||
|
||||
#define QXL_LOG_BUF_SIZE 4096
|
||||
|
||||
#define QXL_INTERRUPT_DISPLAY (1 << 0)
|
||||
#define QXL_INTERRUPT_CURSOR (1 << 1)
|
||||
#define QXL_INTERRUPT_IO_CMD (1 << 2)
|
||||
#define QXL_INTERRUPT_ERROR (1 << 3)
|
||||
#define QXL_INTERRUPT_CLIENT (1 << 4)
|
||||
#define QXL_INTERRUPT_CLIENT_MONITORS_CONFIG (1 << 5)
|
||||
|
||||
/* qxl-1 compat: append only */
|
||||
typedef struct SPICE_ATTR_ALIGNED(4) SPICE_ATTR_PACKED QXLRam {
|
||||
uint32_t magic;
|
||||
uint32_t int_pending;
|
||||
uint32_t int_mask;
|
||||
uint8_t log_buf[QXL_LOG_BUF_SIZE];
|
||||
QXLCommandRing cmd_ring;
|
||||
QXLCursorRing cursor_ring;
|
||||
QXLReleaseRing release_ring;
|
||||
QXLRect update_area;
|
||||
/* appended for qxl-2 */
|
||||
uint32_t update_surface;
|
||||
QXLMemSlot mem_slot;
|
||||
QXLSurfaceCreate create_surface;
|
||||
uint64_t flags;
|
||||
|
||||
/* appended for qxl-4 */
|
||||
|
||||
/* used by QXL_IO_MONITORS_CONFIG_ASYNC */
|
||||
QXLPHYSICAL monitors_config;
|
||||
|
||||
} QXLRam;
|
||||
|
||||
typedef union SPICE_ATTR_PACKED QXLReleaseInfo {
|
||||
uint64_t id; // in
|
||||
uint64_t next; // out
|
||||
} QXLReleaseInfo;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLDataChunk {
|
||||
uint32_t data_size;
|
||||
QXLPHYSICAL prev_chunk;
|
||||
QXLPHYSICAL next_chunk;
|
||||
uint8_t data[0];
|
||||
} QXLDataChunk;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLMessage {
|
||||
QXLReleaseInfo release_info;
|
||||
uint8_t data[0];
|
||||
} QXLMessage;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLCompatUpdateCmd {
|
||||
QXLReleaseInfo release_info;
|
||||
QXLRect area;
|
||||
uint32_t update_id;
|
||||
} QXLCompatUpdateCmd;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLUpdateCmd {
|
||||
QXLReleaseInfo release_info;
|
||||
QXLRect area;
|
||||
uint32_t update_id;
|
||||
uint32_t surface_id;
|
||||
} QXLUpdateCmd;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLCursorHeader {
|
||||
uint64_t unique;
|
||||
uint16_t type;
|
||||
uint16_t width;
|
||||
uint16_t height;
|
||||
uint16_t hot_spot_x;
|
||||
uint16_t hot_spot_y;
|
||||
} QXLCursorHeader;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLCursor {
|
||||
QXLCursorHeader header;
|
||||
uint32_t data_size;
|
||||
QXLDataChunk chunk;
|
||||
} QXLCursor;
|
||||
|
||||
enum {
|
||||
QXL_CURSOR_SET,
|
||||
QXL_CURSOR_MOVE,
|
||||
QXL_CURSOR_HIDE,
|
||||
QXL_CURSOR_TRAIL,
|
||||
};
|
||||
|
||||
#define QXL_CURSUR_DEVICE_DATA_SIZE 128
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLCursorCmd {
|
||||
QXLReleaseInfo release_info;
|
||||
uint8_t type;
|
||||
union {
|
||||
struct SPICE_ATTR_PACKED {
|
||||
QXLPoint16 position;
|
||||
uint8_t visible;
|
||||
QXLPHYSICAL shape;
|
||||
} set;
|
||||
struct SPICE_ATTR_PACKED {
|
||||
uint16_t length;
|
||||
uint16_t frequency;
|
||||
} trail;
|
||||
QXLPoint16 position;
|
||||
} u;
|
||||
uint8_t device_data[QXL_CURSUR_DEVICE_DATA_SIZE]; //todo: dynamic size from rom
|
||||
} QXLCursorCmd;
|
||||
|
||||
enum {
|
||||
QXL_DRAW_NOP,
|
||||
QXL_DRAW_FILL,
|
||||
QXL_DRAW_OPAQUE,
|
||||
QXL_DRAW_COPY,
|
||||
QXL_COPY_BITS,
|
||||
QXL_DRAW_BLEND,
|
||||
QXL_DRAW_BLACKNESS,
|
||||
QXL_DRAW_WHITENESS,
|
||||
QXL_DRAW_INVERS,
|
||||
QXL_DRAW_ROP3,
|
||||
QXL_DRAW_STROKE,
|
||||
QXL_DRAW_TEXT,
|
||||
QXL_DRAW_TRANSPARENT,
|
||||
QXL_DRAW_ALPHA_BLEND,
|
||||
QXL_DRAW_COMPOSITE
|
||||
};
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLRasterGlyph {
|
||||
QXLPoint render_pos;
|
||||
QXLPoint glyph_origin;
|
||||
uint16_t width;
|
||||
uint16_t height;
|
||||
uint8_t data[0];
|
||||
} QXLRasterGlyph;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLString {
|
||||
uint32_t data_size;
|
||||
uint16_t length;
|
||||
uint16_t flags;
|
||||
QXLDataChunk chunk;
|
||||
} QXLString;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLCopyBits {
|
||||
QXLPoint src_pos;
|
||||
} QXLCopyBits;
|
||||
|
||||
typedef enum QXLEffectType
|
||||
{
|
||||
QXL_EFFECT_BLEND = 0,
|
||||
QXL_EFFECT_OPAQUE = 1,
|
||||
QXL_EFFECT_REVERT_ON_DUP = 2,
|
||||
QXL_EFFECT_BLACKNESS_ON_DUP = 3,
|
||||
QXL_EFFECT_WHITENESS_ON_DUP = 4,
|
||||
QXL_EFFECT_NOP_ON_DUP = 5,
|
||||
QXL_EFFECT_NOP = 6,
|
||||
QXL_EFFECT_OPAQUE_BRUSH = 7
|
||||
} QXLEffectType;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLPattern {
|
||||
QXLPHYSICAL pat;
|
||||
QXLPoint pos;
|
||||
} QXLPattern;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLBrush {
|
||||
uint32_t type;
|
||||
union {
|
||||
uint32_t color;
|
||||
QXLPattern pattern;
|
||||
} u;
|
||||
} QXLBrush;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLQMask {
|
||||
uint8_t flags;
|
||||
QXLPoint pos;
|
||||
QXLPHYSICAL bitmap;
|
||||
} QXLQMask;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLFill {
|
||||
QXLBrush brush;
|
||||
uint16_t rop_descriptor;
|
||||
QXLQMask mask;
|
||||
} QXLFill;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLOpaque {
|
||||
QXLPHYSICAL src_bitmap;
|
||||
QXLRect src_area;
|
||||
QXLBrush brush;
|
||||
uint16_t rop_descriptor;
|
||||
uint8_t scale_mode;
|
||||
QXLQMask mask;
|
||||
} QXLOpaque;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLCopy {
|
||||
QXLPHYSICAL src_bitmap;
|
||||
QXLRect src_area;
|
||||
uint16_t rop_descriptor;
|
||||
uint8_t scale_mode;
|
||||
QXLQMask mask;
|
||||
} QXLCopy, QXLBlend;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLTransparent {
|
||||
QXLPHYSICAL src_bitmap;
|
||||
QXLRect src_area;
|
||||
uint32_t src_color;
|
||||
uint32_t true_color;
|
||||
} QXLTransparent;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLAlphaBlend {
|
||||
uint16_t alpha_flags;
|
||||
uint8_t alpha;
|
||||
QXLPHYSICAL src_bitmap;
|
||||
QXLRect src_area;
|
||||
} QXLAlphaBlend;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLCompatAlphaBlend {
|
||||
uint8_t alpha;
|
||||
QXLPHYSICAL src_bitmap;
|
||||
QXLRect src_area;
|
||||
} QXLCompatAlphaBlend;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLRop3 {
|
||||
QXLPHYSICAL src_bitmap;
|
||||
QXLRect src_area;
|
||||
QXLBrush brush;
|
||||
uint8_t rop3;
|
||||
uint8_t scale_mode;
|
||||
QXLQMask mask;
|
||||
} QXLRop3;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLLineAttr {
|
||||
uint8_t flags;
|
||||
uint8_t join_style;
|
||||
uint8_t end_style;
|
||||
uint8_t style_nseg;
|
||||
QXLFIXED width;
|
||||
QXLFIXED miter_limit;
|
||||
QXLPHYSICAL style;
|
||||
} QXLLineAttr;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLStroke {
|
||||
QXLPHYSICAL path;
|
||||
QXLLineAttr attr;
|
||||
QXLBrush brush;
|
||||
uint16_t fore_mode;
|
||||
uint16_t back_mode;
|
||||
} QXLStroke;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLText {
|
||||
QXLPHYSICAL str;
|
||||
QXLRect back_area;
|
||||
QXLBrush fore_brush;
|
||||
QXLBrush back_brush;
|
||||
uint16_t fore_mode;
|
||||
uint16_t back_mode;
|
||||
} QXLText;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLBlackness {
|
||||
QXLQMask mask;
|
||||
} QXLBlackness, QXLInvers, QXLWhiteness;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLClip {
|
||||
uint32_t type;
|
||||
QXLPHYSICAL data;
|
||||
} QXLClip;
|
||||
|
||||
typedef enum {
|
||||
QXL_OP_CLEAR = 0x00,
|
||||
QXL_OP_SOURCE = 0x01,
|
||||
QXL_OP_DST = 0x02,
|
||||
QXL_OP_OVER = 0x03,
|
||||
QXL_OP_OVER_REVERSE = 0x04,
|
||||
QXL_OP_IN = 0x05,
|
||||
QXL_OP_IN_REVERSE = 0x06,
|
||||
QXL_OP_OUT = 0x07,
|
||||
QXL_OP_OUT_REVERSE = 0x08,
|
||||
QXL_OP_ATOP = 0x09,
|
||||
QXL_OP_ATOP_REVERSE = 0x0a,
|
||||
QXL_OP_XOR = 0x0b,
|
||||
QXL_OP_ADD = 0x0c,
|
||||
QXL_OP_SATURATE = 0x0d,
|
||||
/* Note the jump here from 0x0d to 0x30 */
|
||||
QXL_OP_MULTIPLY = 0x30,
|
||||
QXL_OP_SCREEN = 0x31,
|
||||
QXL_OP_OVERLAY = 0x32,
|
||||
QXL_OP_DARKEN = 0x33,
|
||||
QXL_OP_LIGHTEN = 0x34,
|
||||
QXL_OP_COLOR_DODGE = 0x35,
|
||||
QXL_OP_COLOR_BURN = 0x36,
|
||||
QXL_OP_HARD_LIGHT = 0x37,
|
||||
QXL_OP_SOFT_LIGHT = 0x38,
|
||||
QXL_OP_DIFFERENCE = 0x39,
|
||||
QXL_OP_EXCLUSION = 0x3a,
|
||||
QXL_OP_HSL_HUE = 0x3b,
|
||||
QXL_OP_HSL_SATURATION = 0x3c,
|
||||
QXL_OP_HSL_COLOR = 0x3d,
|
||||
QXL_OP_HSL_LUMINOSITY = 0x3e
|
||||
} QXLOperator;
|
||||
|
||||
typedef struct {
|
||||
uint32_t t00;
|
||||
uint32_t t01;
|
||||
uint32_t t02;
|
||||
uint32_t t10;
|
||||
uint32_t t11;
|
||||
uint32_t t12;
|
||||
} QXLTransform;
|
||||
|
||||
/* The flags field has the following bit fields:
|
||||
*
|
||||
* operator: [ 0 - 7 ]
|
||||
* src_filter: [ 8 - 10 ]
|
||||
* mask_filter: [ 11 - 13 ]
|
||||
* src_repeat: [ 14 - 15 ]
|
||||
* mask_repeat: [ 16 - 17 ]
|
||||
* component_alpha: [ 18 - 18 ]
|
||||
* reserved: [ 19 - 31 ]
|
||||
*
|
||||
* The repeat and filter values are those of pixman:
|
||||
* REPEAT_NONE = 0
|
||||
* REPEAT_NORMAL = 1
|
||||
* REPEAT_PAD = 2
|
||||
* REPEAT_REFLECT = 3
|
||||
*
|
||||
* The filter values are:
|
||||
* FILTER_NEAREST = 0
|
||||
* FILTER_BILINEAR = 1
|
||||
*/
|
||||
typedef struct SPICE_ATTR_PACKED QXLComposite {
|
||||
uint32_t flags;
|
||||
|
||||
QXLPHYSICAL src;
|
||||
QXLPHYSICAL src_transform; /* May be NULL */
|
||||
QXLPHYSICAL mask; /* May be NULL */
|
||||
QXLPHYSICAL mask_transform; /* May be NULL */
|
||||
QXLPoint16 src_origin;
|
||||
QXLPoint16 mask_origin;
|
||||
} QXLComposite;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLCompatDrawable {
|
||||
QXLReleaseInfo release_info;
|
||||
uint8_t effect;
|
||||
uint8_t type;
|
||||
uint16_t bitmap_offset;
|
||||
QXLRect bitmap_area;
|
||||
QXLRect bbox;
|
||||
QXLClip clip;
|
||||
uint32_t mm_time;
|
||||
union {
|
||||
QXLFill fill;
|
||||
QXLOpaque opaque;
|
||||
QXLCopy copy;
|
||||
QXLTransparent transparent;
|
||||
QXLCompatAlphaBlend alpha_blend;
|
||||
QXLCopyBits copy_bits;
|
||||
QXLBlend blend;
|
||||
QXLRop3 rop3;
|
||||
QXLStroke stroke;
|
||||
QXLText text;
|
||||
QXLBlackness blackness;
|
||||
QXLInvers invers;
|
||||
QXLWhiteness whiteness;
|
||||
} u;
|
||||
} QXLCompatDrawable;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLDrawable {
|
||||
QXLReleaseInfo release_info;
|
||||
uint32_t surface_id;
|
||||
uint8_t effect;
|
||||
uint8_t type;
|
||||
uint8_t self_bitmap;
|
||||
QXLRect self_bitmap_area;
|
||||
QXLRect bbox;
|
||||
QXLClip clip;
|
||||
uint32_t mm_time;
|
||||
int32_t surfaces_dest[3];
|
||||
QXLRect surfaces_rects[3];
|
||||
union {
|
||||
QXLFill fill;
|
||||
QXLOpaque opaque;
|
||||
QXLCopy copy;
|
||||
QXLTransparent transparent;
|
||||
QXLAlphaBlend alpha_blend;
|
||||
QXLCopyBits copy_bits;
|
||||
QXLBlend blend;
|
||||
QXLRop3 rop3;
|
||||
QXLStroke stroke;
|
||||
QXLText text;
|
||||
QXLBlackness blackness;
|
||||
QXLInvers invers;
|
||||
QXLWhiteness whiteness;
|
||||
QXLComposite composite;
|
||||
} u;
|
||||
} QXLDrawable;
|
||||
|
||||
typedef enum QXLSurfaceCmdType {
|
||||
QXL_SURFACE_CMD_CREATE,
|
||||
QXL_SURFACE_CMD_DESTROY,
|
||||
} QXLSurfaceCmdType;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLSurface {
|
||||
uint32_t format;
|
||||
uint32_t width;
|
||||
uint32_t height;
|
||||
int32_t stride;
|
||||
QXLPHYSICAL data;
|
||||
} QXLSurface;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLSurfaceCmd {
|
||||
QXLReleaseInfo release_info;
|
||||
uint32_t surface_id;
|
||||
uint8_t type;
|
||||
uint32_t flags;
|
||||
union {
|
||||
QXLSurface surface_create;
|
||||
} u;
|
||||
} QXLSurfaceCmd;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLClipRects {
|
||||
uint32_t num_rects;
|
||||
QXLDataChunk chunk;
|
||||
} QXLClipRects;
|
||||
|
||||
enum {
|
||||
QXL_PATH_BEGIN = (1 << 0),
|
||||
QXL_PATH_END = (1 << 1),
|
||||
QXL_PATH_CLOSE = (1 << 3),
|
||||
QXL_PATH_BEZIER = (1 << 4),
|
||||
};
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLPathSeg {
|
||||
uint32_t flags;
|
||||
uint32_t count;
|
||||
QXLPointFix points[0];
|
||||
} QXLPathSeg;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLPath {
|
||||
uint32_t data_size;
|
||||
QXLDataChunk chunk;
|
||||
} QXLPath;
|
||||
|
||||
enum {
|
||||
QXL_IMAGE_GROUP_DRIVER,
|
||||
QXL_IMAGE_GROUP_DEVICE,
|
||||
QXL_IMAGE_GROUP_RED,
|
||||
QXL_IMAGE_GROUP_DRIVER_DONT_CACHE,
|
||||
};
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLImageID {
|
||||
uint32_t group;
|
||||
uint32_t unique;
|
||||
} QXLImageID;
|
||||
|
||||
typedef union {
|
||||
QXLImageID id;
|
||||
uint64_t value;
|
||||
} QXLImageIDUnion;
|
||||
|
||||
typedef enum QXLImageFlags {
|
||||
QXL_IMAGE_CACHE = (1 << 0),
|
||||
QXL_IMAGE_HIGH_BITS_SET = (1 << 1),
|
||||
} QXLImageFlags;
|
||||
|
||||
typedef enum QXLBitmapFlags {
|
||||
QXL_BITMAP_DIRECT = (1 << 0),
|
||||
QXL_BITMAP_UNSTABLE = (1 << 1),
|
||||
QXL_BITMAP_TOP_DOWN = (1 << 2), // == SPICE_BITMAP_FLAGS_TOP_DOWN
|
||||
} QXLBitmapFlags;
|
||||
|
||||
#define QXL_SET_IMAGE_ID(image, _group, _unique) { \
|
||||
(image)->descriptor.id = (((uint64_t)_unique) << 32) | _group; \
|
||||
}
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLImageDescriptor {
|
||||
uint64_t id;
|
||||
uint8_t type;
|
||||
uint8_t flags;
|
||||
uint32_t width;
|
||||
uint32_t height;
|
||||
} QXLImageDescriptor;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLPalette {
|
||||
uint64_t unique;
|
||||
uint16_t num_ents;
|
||||
uint32_t ents[0];
|
||||
} QXLPalette;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLBitmap {
|
||||
uint8_t format;
|
||||
uint8_t flags;
|
||||
uint32_t x;
|
||||
uint32_t y;
|
||||
uint32_t stride;
|
||||
QXLPHYSICAL palette;
|
||||
QXLPHYSICAL data; //data[0] ?
|
||||
} QXLBitmap;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLSurfaceId {
|
||||
uint32_t surface_id;
|
||||
} QXLSurfaceId;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLQUICData {
|
||||
uint32_t data_size;
|
||||
/* This data for QUIC is a QXLDataChunk.
|
||||
* This differs from QXLBitmap where it's a reference to bitmap data or
|
||||
* a reference to QXLDataChunk */
|
||||
uint8_t data[0];
|
||||
} QXLQUICData, QXLLZRGBData, QXLJPEGData;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLImage {
|
||||
QXLImageDescriptor descriptor;
|
||||
union { // variable length
|
||||
QXLBitmap bitmap;
|
||||
QXLQUICData quic;
|
||||
QXLSurfaceId surface_image;
|
||||
};
|
||||
} QXLImage;
|
||||
|
||||
/* A QXLHead is a single monitor output backed by a QXLSurface.
|
||||
* x and y offsets are unsigned since they are used in relation to
|
||||
* the given surface, not the same as the x, y coordinates in the guest
|
||||
* screen reference frame. */
|
||||
typedef struct SPICE_ATTR_PACKED QXLHead {
|
||||
uint32_t id;
|
||||
uint32_t surface_id;
|
||||
uint32_t width;
|
||||
uint32_t height;
|
||||
uint32_t x;
|
||||
uint32_t y;
|
||||
uint32_t flags;
|
||||
} QXLHead;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLMonitorsConfig {
|
||||
uint16_t count;
|
||||
uint16_t max_allowed; /* If it is 0 no fixed limit is given by the driver */
|
||||
QXLHead heads[0];
|
||||
} QXLMonitorsConfig;
|
||||
|
||||
#include <spice/end-packed.h>
|
||||
|
||||
typedef struct QXLReleaseInfoExt {
|
||||
QXLReleaseInfo *info;
|
||||
uint32_t group_id;
|
||||
} QXLReleaseInfoExt;
|
||||
|
||||
#endif /* _H_QXL_DEV */
|
||||
21
spice/qxl_windows.h
Normal file
21
spice/qxl_windows.h
Normal file
@ -0,0 +1,21 @@
|
||||
#ifndef _H_QXL_WINDOWS
|
||||
#define _H_QXL_WINDOWS
|
||||
|
||||
#include <spice/types.h>
|
||||
|
||||
#include <spice/start-packed.h>
|
||||
|
||||
enum {
|
||||
QXL_ESCAPE_SET_CUSTOM_DISPLAY = 0x10001,
|
||||
QXL_ESCAPE_MONITOR_CONFIG
|
||||
};
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED QXLEscapeSetCustomDisplay {
|
||||
uint32_t xres;
|
||||
uint32_t yres;
|
||||
uint32_t bpp;
|
||||
} QXLEscapeSetCustomDisplay;
|
||||
|
||||
#include <spice/end-packed.h>
|
||||
|
||||
#endif /* _H_QXL_WINDOWS */
|
||||
66
spice/start-packed.h
Normal file
66
spice/start-packed.h
Normal file
@ -0,0 +1,66 @@
|
||||
/* -*- Mode: C; tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- */
|
||||
/*
|
||||
Copyright (C) 2009 Red Hat, Inc.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are
|
||||
met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
* Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in
|
||||
the documentation and/or other materials provided with the
|
||||
distribution.
|
||||
* Neither the name of the copyright holder nor the names of its
|
||||
contributors may be used to endorse or promote products derived
|
||||
from this software without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS "AS
|
||||
IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
||||
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
||||
PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
/* Ideally this should all have been macros in a common headers, but
|
||||
* its not possible to put pragmas into macros, so we have to use
|
||||
* include magic.
|
||||
*
|
||||
* Use it like this:
|
||||
*
|
||||
* #include <spice/start-packed.h>
|
||||
*
|
||||
* typedef struct SPICE_ATTR_PACKED {
|
||||
* ...
|
||||
* } Type;
|
||||
*
|
||||
* #include <spice/end-packed.h>
|
||||
*
|
||||
*/
|
||||
|
||||
#ifdef __GNUC__
|
||||
|
||||
#define SPICE_ATTR_PACKED __attribute__ ((__packed__))
|
||||
#define SPICE_ATTR_ALIGNED(n) __attribute__ ((__aligned__ (n)))
|
||||
|
||||
#ifdef __MINGW32__
|
||||
#pragma pack(push,1)
|
||||
#endif
|
||||
|
||||
#else
|
||||
|
||||
#pragma pack(push)
|
||||
#pragma pack(1)
|
||||
#define SPICE_ATTR_PACKED
|
||||
#define SPICE_ATTR_ALIGNED(n) __declspec (align (n))
|
||||
#pragma warning(disable:4200)
|
||||
#pragma warning(disable:4103)
|
||||
|
||||
#endif
|
||||
70
spice/stats.h
Normal file
70
spice/stats.h
Normal file
@ -0,0 +1,70 @@
|
||||
/*
|
||||
Copyright (C) 2009 Red Hat, Inc.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are
|
||||
met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
* Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in
|
||||
the documentation and/or other materials provided with the
|
||||
distribution.
|
||||
* Neither the name of the copyright holder nor the names of its
|
||||
contributors may be used to endorse or promote products derived
|
||||
from this software without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS "AS
|
||||
IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
||||
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
||||
PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#ifndef _H_SPICE_STATS
|
||||
#define _H_SPICE_STATS
|
||||
|
||||
#include <spice/macros.h>
|
||||
#include <spice/types.h>
|
||||
|
||||
#define SPICE_STAT_SHM_NAME "/spice.%u"
|
||||
#define SPICE_STAT_NODE_NAME_MAX 20
|
||||
#define SPICE_STAT_MAGIC SPICE_MAGIC_CONST("STAT")
|
||||
#define SPICE_STAT_VERSION 1
|
||||
|
||||
enum {
|
||||
SPICE_STAT_NODE_FLAG_ENABLED = (1 << 0),
|
||||
SPICE_STAT_NODE_FLAG_VISIBLE = (1 << 1),
|
||||
SPICE_STAT_NODE_FLAG_VALUE = (1 << 2),
|
||||
};
|
||||
|
||||
#define SPICE_STAT_NODE_MASK_SHOW (SPICE_STAT_NODE_FLAG_ENABLED | SPICE_STAT_NODE_FLAG_VISIBLE)
|
||||
#define SPICE_STAT_NODE_MASK_SHOW_VALUE (SPICE_STAT_NODE_MASK_SHOW | SPICE_STAT_NODE_FLAG_VALUE)
|
||||
|
||||
typedef struct SpiceStatNode {
|
||||
uint64_t value;
|
||||
uint32_t flags;
|
||||
uint32_t next_sibling_index;
|
||||
uint32_t first_child_index;
|
||||
char name[SPICE_STAT_NODE_NAME_MAX];
|
||||
} SpiceStatNode;
|
||||
|
||||
typedef struct SpiceStat {
|
||||
uint32_t magic;
|
||||
uint32_t version;
|
||||
uint32_t generation;
|
||||
uint32_t num_of_nodes;
|
||||
uint32_t root_index;
|
||||
/* to avoid holes in the structure on some platforms */
|
||||
uint32_t padding;
|
||||
SpiceStatNode nodes[];
|
||||
} SpiceStat;
|
||||
|
||||
#endif /* _H_SPICE_STATS */
|
||||
270
spice/stream-device.h
Normal file
270
spice/stream-device.h
Normal file
@ -0,0 +1,270 @@
|
||||
/*
|
||||
Copyright (C) 2017-2018 Red Hat, Inc.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are
|
||||
met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
* Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in
|
||||
the documentation and/or other materials provided with the
|
||||
distribution.
|
||||
* Neither the name of the copyright holder nor the names of its
|
||||
contributors may be used to endorse or promote products derived
|
||||
from this software without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS "AS
|
||||
IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
||||
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
||||
PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* This header contains definition for the device that
|
||||
* allows to send streamed data to the server.
|
||||
*
|
||||
* The device is currently implemented as a VirtIO port inside the
|
||||
* guest. The guest should open that device to use this protocol to
|
||||
* communicate with the host.
|
||||
*/
|
||||
|
||||
#ifndef SPICE_STREAM_DEVICE_H_
|
||||
#define SPICE_STREAM_DEVICE_H_
|
||||
|
||||
#include <spice/types.h>
|
||||
|
||||
/*
|
||||
* Structures are all "naturally aligned"
|
||||
* containing integers up to 64 bit.
|
||||
* All numbers are in little endian format.
|
||||
*
|
||||
* For security reasons structures should not contain implicit paddings.
|
||||
*
|
||||
* The protocol can be defined by these states:
|
||||
* - Initial. Device just opened. Guest should wait
|
||||
* for a message from the host;
|
||||
* - Idle. No streaming allowed;
|
||||
* - Ready. Server sent list of possible codecs;
|
||||
* - Streaming. Stream active, enabled by the guest.
|
||||
*/
|
||||
|
||||
/* version of the protocol */
|
||||
#define STREAM_DEVICE_PROTOCOL 1
|
||||
|
||||
typedef struct StreamDevHeader {
|
||||
/* should be STREAM_DEVICE_PROTOCOL */
|
||||
uint8_t protocol_version;
|
||||
/* reserved, should be set to 0 */
|
||||
uint8_t padding;
|
||||
/* as defined in StreamMsgType enumeration */
|
||||
uint16_t type;
|
||||
/* size of the following message.
|
||||
* A message of type STREAM_TYPE_XXX_YYY is represented with a
|
||||
* corresponding StreamMsgXxxYyy structure. */
|
||||
uint32_t size;
|
||||
} StreamDevHeader;
|
||||
|
||||
typedef enum StreamMsgType {
|
||||
/* invalid, do not use */
|
||||
STREAM_TYPE_INVALID = 0,
|
||||
/* allows to send version information */
|
||||
STREAM_TYPE_CAPABILITIES,
|
||||
/* send screen resolution */
|
||||
STREAM_TYPE_FORMAT,
|
||||
/* stream data */
|
||||
STREAM_TYPE_DATA,
|
||||
/* server ask to start a new stream */
|
||||
STREAM_TYPE_START_STOP,
|
||||
/* server notify errors to guest */
|
||||
STREAM_TYPE_NOTIFY_ERROR,
|
||||
/* guest cursor */
|
||||
STREAM_TYPE_CURSOR_SET,
|
||||
/* guest cursor position */
|
||||
STREAM_TYPE_CURSOR_MOVE,
|
||||
/* the graphics device display information message (device address and display id) */
|
||||
STREAM_TYPE_DEVICE_DISPLAY_INFO,
|
||||
/* video encoding quality indicator message */
|
||||
STREAM_TYPE_QUALITY_INDICATOR,
|
||||
} StreamMsgType;
|
||||
|
||||
typedef enum StreamCapabilities {
|
||||
/* handling of STREAM_TYPE_QUALITY_INDICATOR messages */
|
||||
STREAM_CAP_QUALITY_INDICATOR,
|
||||
STREAM_CAP_END // this must be the last
|
||||
} StreamCapabilities;
|
||||
|
||||
/* Generic extension capabilities.
|
||||
* This is a set of bits to specify which capabilities host and guest support.
|
||||
* This message is sent by the host to the guest or by the guest to the host.
|
||||
* Should be sent as first message.
|
||||
* If it is not sent, it means that guest/host doesn't support any extension.
|
||||
* Guest should send this as a reply from same type of message
|
||||
* from the host.
|
||||
* This message should be limited to STREAM_MSG_CAPABILITIES_MAX_BYTES. This
|
||||
* allows plenty of negotiations.
|
||||
*
|
||||
* States allowed: Initial(host), Idle(guest)
|
||||
* state will change to Idle.
|
||||
*/
|
||||
typedef struct StreamMsgCapabilities {
|
||||
uint8_t capabilities[0];
|
||||
} StreamMsgCapabilities;
|
||||
|
||||
#define STREAM_MSG_CAPABILITIES_MAX_BYTES 1024
|
||||
|
||||
/* Define the format of the stream, start a new stream.
|
||||
* This message is sent by the guest to the host to
|
||||
* tell the host the new stream format.
|
||||
*
|
||||
* States allowed: Ready
|
||||
* state will change to Streaming.
|
||||
*/
|
||||
typedef struct StreamMsgFormat {
|
||||
/* screen resolution/stream size */
|
||||
uint32_t width;
|
||||
uint32_t height;
|
||||
/* as defined in SpiceVideoCodecType enumeration */
|
||||
uint8_t codec;
|
||||
uint8_t padding1[3];
|
||||
} StreamMsgFormat;
|
||||
|
||||
/* This message contains just raw data stream.
|
||||
* This message is sent by the guest to the host.
|
||||
*
|
||||
* States allowed: Streaming
|
||||
*/
|
||||
typedef struct StreamMsgData {
|
||||
uint8_t data[0];
|
||||
} StreamMsgData;
|
||||
|
||||
/* This message contains information about the graphics device and monitor
|
||||
* belonging to a particular video stream (which maps to a channel) from
|
||||
* the streaming agent.
|
||||
*
|
||||
* The device_address is the hardware address of the device (e.g. PCI),
|
||||
* device_display_id is the id of the monitor on the device.
|
||||
*
|
||||
* The supported device address format is:
|
||||
* "pci/<DOMAIN>/<SLOT>.<FUNCTION>/.../<SLOT>.<FUNCTION>"
|
||||
*
|
||||
* The "pci" identifies the rest of the string as a PCI address. It is the only
|
||||
* supported address at the moment, other identifiers can be introduced later.
|
||||
* <DOMAIN> is the PCI domain, followed by <SLOT>.<FUNCTION> of any PCI bridges
|
||||
* in the chain leading to the device. The last <SLOT>.<FUNCTION> is the
|
||||
* graphics device. All of <DOMAIN>, <SLOT>, <FUNCTION> are hexadecimal numbers
|
||||
* with the following number of digits:
|
||||
* <DOMAIN>: 4
|
||||
* <SLOT>: 2
|
||||
* <FUNCTION>: 1
|
||||
*
|
||||
* Sent from the streaming agent to the server.
|
||||
*/
|
||||
typedef struct StreamMsgDeviceDisplayInfo {
|
||||
uint32_t stream_id;
|
||||
uint32_t device_display_id;
|
||||
uint32_t device_address_len;
|
||||
uint8_t device_address[0]; // a zero-terminated string
|
||||
} StreamMsgDeviceDisplayInfo;
|
||||
|
||||
/* This message contains a quality indicator string, generated by the
|
||||
* streaming agent. It is indended to be used by a module running of
|
||||
* the server to ajust the streaming quality.
|
||||
*
|
||||
* The format of the string message is not specificied because
|
||||
* module-specific.
|
||||
*
|
||||
* This message is sent by the guest to the host.
|
||||
*
|
||||
* States allowed: any
|
||||
*
|
||||
* Capability required: STREAM_CAP_QUALITY_INDICATOR
|
||||
*/
|
||||
typedef struct StreamMsgQualityIndicator {
|
||||
uint8_t quality[0]; // a zero-terminated string
|
||||
} StreamMsgQualityIndicator;
|
||||
|
||||
/* Tell to stop current stream and possibly start a new one.
|
||||
* This message is sent by the host to the guest.
|
||||
* Allows to communicate the codecs supported by the clients.
|
||||
* The agent should stop the old stream and if any codec in the
|
||||
* list is supported start streaming (as Mjpeg is always supported
|
||||
* agent should stop only on a real stop request).
|
||||
*
|
||||
* States allowed: any
|
||||
* state will change to Idle (no codecs) or Ready
|
||||
*/
|
||||
typedef struct StreamMsgStartStop {
|
||||
/* supported codecs, 0 to stop streaming */
|
||||
uint8_t num_codecs;
|
||||
/* as defined in SpiceVideoCodecType enumeration */
|
||||
uint8_t codecs[0];
|
||||
} StreamMsgStartStop;
|
||||
|
||||
/* Tell guest about invalid protocol.
|
||||
* This message is sent by the host to the guest.
|
||||
* The server will stop processing data from the guest.
|
||||
*
|
||||
* States allowed: any
|
||||
*/
|
||||
typedef struct StreamMsgNotifyError {
|
||||
/* numeric error code.
|
||||
* Currently not defined, set to 0.
|
||||
*/
|
||||
uint32_t error_code;
|
||||
/* String message, UTF-8 encoded.
|
||||
* This field terminate with the message.
|
||||
* Not necessary NUL-terminated.
|
||||
*/
|
||||
uint8_t msg[0];
|
||||
} StreamMsgNotifyError;
|
||||
|
||||
#define STREAM_MSG_CURSOR_SET_MAX_WIDTH 1024
|
||||
#define STREAM_MSG_CURSOR_SET_MAX_HEIGHT 1024
|
||||
|
||||
/* Guest cursor.
|
||||
* This message is sent by the guest to the host.
|
||||
*
|
||||
* States allowed: Streaming
|
||||
*/
|
||||
typedef struct StreamMsgCursorSet {
|
||||
/* basic cursor information */
|
||||
/* for security reasons width and height should
|
||||
* be limited to STREAM_MSG_CURSOR_SET_MAX_WIDTH and
|
||||
* STREAM_MSG_CURSOR_SET_MAX_HEIGHT */
|
||||
uint16_t width;
|
||||
uint16_t height;
|
||||
uint16_t hot_spot_x;
|
||||
uint16_t hot_spot_y;
|
||||
/* Cursor type, as defined by SpiceCursorType.
|
||||
* Only ALPHA, COLOR24 and COLOR32 are allowed by this protocol
|
||||
*/
|
||||
uint8_t type;
|
||||
|
||||
uint8_t padding1[3];
|
||||
|
||||
/* cursor data.
|
||||
* Format and size depends on cursor_header type and size
|
||||
*/
|
||||
uint8_t data[0];
|
||||
} StreamMsgCursorSet;
|
||||
|
||||
/* Guest cursor position
|
||||
* This message is sent by the guest to the host.
|
||||
*
|
||||
* States allowed: Streaming
|
||||
*/
|
||||
typedef struct StreamMsgCursorMove {
|
||||
int32_t x;
|
||||
int32_t y;
|
||||
} StreamMsgCursorMove;
|
||||
|
||||
#endif /* SPICE_STREAM_DEVICE_H_ */
|
||||
41
spice/types.h
Normal file
41
spice/types.h
Normal file
@ -0,0 +1,41 @@
|
||||
/* -*- Mode: C; tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- */
|
||||
/*
|
||||
Copyright (C) 2009 Red Hat, Inc.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are
|
||||
met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
* Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in
|
||||
the documentation and/or other materials provided with the
|
||||
distribution.
|
||||
* Neither the name of the copyright holder nor the names of its
|
||||
contributors may be used to endorse or promote products derived
|
||||
from this software without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS "AS
|
||||
IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
||||
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
||||
PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#ifndef _H_SPICE_TYPES
|
||||
#define _H_SPICE_TYPES
|
||||
|
||||
/* We always want the standard int types
|
||||
* If they are not in stdint.h on your system,
|
||||
* include the right one here. */
|
||||
#include <stdint.h>
|
||||
#include <limits.h>
|
||||
|
||||
#endif /* _H_SPICE_TYPES */
|
||||
410
spice/vd_agent.h
Normal file
410
spice/vd_agent.h
Normal file
@ -0,0 +1,410 @@
|
||||
/*
|
||||
Copyright (C) 2009 Red Hat, Inc.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are
|
||||
met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
* Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in
|
||||
the documentation and/or other materials provided with the
|
||||
distribution.
|
||||
* Neither the name of the copyright holder nor the names of its
|
||||
contributors may be used to endorse or promote products derived
|
||||
from this software without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS "AS
|
||||
IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
||||
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
||||
PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#ifndef _H_VD_AGENT
|
||||
#define _H_VD_AGENT
|
||||
|
||||
#include <spice/types.h>
|
||||
|
||||
#include <spice/start-packed.h>
|
||||
|
||||
enum {
|
||||
VDP_CLIENT_PORT = 1,
|
||||
VDP_SERVER_PORT,
|
||||
VDP_END_PORT
|
||||
};
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED VDIChunkHeader {
|
||||
uint32_t port;
|
||||
uint32_t size;
|
||||
} VDIChunkHeader;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentMessage {
|
||||
/* Should be VD_AGENT_PROTOCOL */
|
||||
uint32_t protocol;
|
||||
/* One of VD_AGENT_xxx in the enumeration below */
|
||||
uint32_t type;
|
||||
uint64_t opaque;
|
||||
/* Size of data following */
|
||||
uint32_t size;
|
||||
uint8_t data[0];
|
||||
} VDAgentMessage;
|
||||
|
||||
#define VD_AGENT_PROTOCOL 1
|
||||
#define VD_AGENT_MAX_DATA_SIZE 2048
|
||||
|
||||
/*
|
||||
* Messages and types for guest agent.
|
||||
* These messages are sent through the virtio port "com.redhat.spice.0"
|
||||
* (agent <-> server) or embedded in "agent_data" SPICE protocol message in
|
||||
* the "MainChannel" (server <-> client)
|
||||
*/
|
||||
enum {
|
||||
/* server -> agent
|
||||
* See VDAgentMouseState structure.
|
||||
*/
|
||||
VD_AGENT_MOUSE_STATE = 1,
|
||||
/* client -> agent|server.
|
||||
* Acknowledged by the agent using VD_AGENT_REPLY.
|
||||
* See VDAgentMonitorsConfig structure.
|
||||
*/
|
||||
VD_AGENT_MONITORS_CONFIG,
|
||||
/* agent -> client.
|
||||
* See VDAgentReply structure.
|
||||
*/
|
||||
VD_AGENT_REPLY,
|
||||
/* Set clipboard data (both directions).
|
||||
* Message comes with type and data.
|
||||
* See VDAgentClipboard structure.
|
||||
*/
|
||||
VD_AGENT_CLIPBOARD,
|
||||
/* client -> agent.
|
||||
* Acknowledged by Windows agent using VD_AGENT_REPLY.
|
||||
* See VDAgentDisplayConfig structure.
|
||||
*/
|
||||
VD_AGENT_DISPLAY_CONFIG,
|
||||
/* See VDAgentAnnounceCapabilities structure. */
|
||||
VD_AGENT_ANNOUNCE_CAPABILITIES,
|
||||
/* Asks to listen for clipboard changes (both directions).
|
||||
* Remote should empty clipboard and wait for one
|
||||
* of the types passed.
|
||||
* See VDAgentClipboardGrab structure.
|
||||
*/
|
||||
VD_AGENT_CLIPBOARD_GRAB,
|
||||
/* Asks for clipboard data (both directions).
|
||||
* Request comes with a specific type.
|
||||
* See VDAgentClipboardRequest structure.
|
||||
*/
|
||||
VD_AGENT_CLIPBOARD_REQUEST,
|
||||
/* See VDAgentClipboardRelease structure. */
|
||||
VD_AGENT_CLIPBOARD_RELEASE,
|
||||
/* See VDAgentFileXferStartMessage structure. */
|
||||
VD_AGENT_FILE_XFER_START,
|
||||
/* See VDAgentFileXferStatusMessage structure. */
|
||||
VD_AGENT_FILE_XFER_STATUS,
|
||||
/* See VDAgentFileXferDataMessage structure. */
|
||||
VD_AGENT_FILE_XFER_DATA,
|
||||
/* Empty message */
|
||||
VD_AGENT_CLIENT_DISCONNECTED,
|
||||
/* See VDAgentMaxClipboard structure. */
|
||||
VD_AGENT_MAX_CLIPBOARD,
|
||||
/* See VDAgentAudioVolumeSync structure. */
|
||||
VD_AGENT_AUDIO_VOLUME_SYNC,
|
||||
/* See VDAgentGraphicsDeviceInfo structure. */
|
||||
VD_AGENT_GRAPHICS_DEVICE_INFO,
|
||||
VD_AGENT_END_MESSAGE,
|
||||
};
|
||||
|
||||
enum {
|
||||
VD_AGENT_FILE_XFER_STATUS_CAN_SEND_DATA,
|
||||
VD_AGENT_FILE_XFER_STATUS_CANCELLED,
|
||||
VD_AGENT_FILE_XFER_STATUS_ERROR,
|
||||
VD_AGENT_FILE_XFER_STATUS_SUCCESS,
|
||||
VD_AGENT_FILE_XFER_STATUS_NOT_ENOUGH_SPACE,
|
||||
VD_AGENT_FILE_XFER_STATUS_SESSION_LOCKED,
|
||||
VD_AGENT_FILE_XFER_STATUS_VDAGENT_NOT_CONNECTED,
|
||||
VD_AGENT_FILE_XFER_STATUS_DISABLED,
|
||||
};
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentFileXferStatusMessage {
|
||||
uint32_t id;
|
||||
uint32_t result;
|
||||
/* Used to send additional data for detailed error messages
|
||||
* to clients with VD_AGENT_CAP_FILE_XFER_DETAILED_ERRORS capability.
|
||||
* Type of data varies with the result:
|
||||
* result : data type (NULL if no data)
|
||||
* VD_AGENT_FILE_XFER_STATUS_ERROR : VDAgentFileXferStatusError
|
||||
* VD_AGENT_FILE_XFER_STATUS_NOT_ENOUGH_SPACE : VDAgentFileXferStatusNotEnoughSpace
|
||||
* VD_AGENT_FILE_XFER_STATUS_SESSION_LOCKED : NULL
|
||||
* VD_AGENT_FILE_XFER_STATUS_VDAGENT_NOT_CONNECTED : NULL
|
||||
* VD_AGENT_FILE_XFER_STATUS_DISABLED : NULL
|
||||
*/
|
||||
uint8_t data[0];
|
||||
} VDAgentFileXferStatusMessage;
|
||||
|
||||
/* Detailed error for VD_AGENT_FILE_XFER_STATUS_NOT_ENOUGH_SPACE.
|
||||
* Only present if VD_AGENT_CAP_FILE_XFER_DETAILED_ERRORS is
|
||||
* negotiated and the size of the message can contain it.
|
||||
*/
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentFileXferStatusNotEnoughSpace {
|
||||
/* Disk free space in bytes. */
|
||||
uint64_t disk_free_space;
|
||||
} VDAgentFileXferStatusNotEnoughSpace;
|
||||
|
||||
enum {
|
||||
/* Error number is a G_IO_ERROR_xxx defined in
|
||||
* https://developer.gnome.org/gio/stable/gio-GIOError.html
|
||||
*/
|
||||
VD_AGENT_FILE_XFER_STATUS_ERROR_GLIB_IO,
|
||||
};
|
||||
|
||||
/* Detailed error for VD_AGENT_FILE_XFER_STATUS_ERROR.
|
||||
* Only present if VD_AGENT_CAP_FILE_XFER_DETAILED_ERRORS is
|
||||
* negotiated and the size of the message can contain it.
|
||||
* Otherwise a generic error should be assumed and reported.
|
||||
*/
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentFileXferStatusError {
|
||||
/* One of VD_AGENT_FILE_XFER_STATUS_ERROR_xxx enumeration
|
||||
*/
|
||||
uint8_t error_type;
|
||||
/* An error code which enumeration depends on error_type
|
||||
*/
|
||||
uint32_t error_code;
|
||||
} VDAgentFileXferStatusError;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentFileXferStartMessage {
|
||||
uint32_t id;
|
||||
uint8_t data[0];
|
||||
} VDAgentFileXferStartMessage;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentFileXferDataMessage {
|
||||
uint32_t id;
|
||||
uint64_t size;
|
||||
uint8_t data[0];
|
||||
} VDAgentFileXferDataMessage;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentMonConfig {
|
||||
/*
|
||||
* Note a width and height of 0 can be used to indicate a disabled
|
||||
* monitor, this may only be used with agents with the
|
||||
* VD_AGENT_CAP_SPARSE_MONITORS_CONFIG capability.
|
||||
*/
|
||||
uint32_t height;
|
||||
uint32_t width;
|
||||
uint32_t depth;
|
||||
int32_t x;
|
||||
int32_t y;
|
||||
} VDAgentMonConfig;
|
||||
|
||||
enum {
|
||||
VD_AGENT_CONFIG_MONITORS_FLAG_USE_POS = (1 << 0),
|
||||
VD_AGENT_CONFIG_MONITORS_FLAG_PHYSICAL_SIZE = (1 << 1),
|
||||
};
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentMonitorsConfig {
|
||||
uint32_t num_of_monitors;
|
||||
uint32_t flags;
|
||||
VDAgentMonConfig monitors[0];
|
||||
/* only sent if the FLAG_PHYSICAL_SIZE is present: */
|
||||
/* VDAgentMonitorMM physical_sizes[0]; */
|
||||
} VDAgentMonitorsConfig;
|
||||
|
||||
|
||||
/* Physical size of the monitor in millimeters.
|
||||
* Having this information, the remote/guest display can configure itself with
|
||||
* appropriate font & scaling to maintain readability. */
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentMonitorMM {
|
||||
/*
|
||||
* Note a width and height of 0 can be used to indicate a disabled
|
||||
* monitor or no size information is present.
|
||||
*/
|
||||
uint16_t height;
|
||||
uint16_t width;
|
||||
} VDAgentMonitorMM;
|
||||
|
||||
enum {
|
||||
VD_AGENT_DISPLAY_CONFIG_FLAG_DISABLE_WALLPAPER = (1 << 0),
|
||||
VD_AGENT_DISPLAY_CONFIG_FLAG_DISABLE_FONT_SMOOTH = (1 << 1),
|
||||
VD_AGENT_DISPLAY_CONFIG_FLAG_DISABLE_ANIMATION = (1 << 2),
|
||||
VD_AGENT_DISPLAY_CONFIG_FLAG_SET_COLOR_DEPTH = (1 << 3),
|
||||
};
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentDisplayConfig {
|
||||
uint32_t flags;
|
||||
uint32_t depth;
|
||||
} VDAgentDisplayConfig;
|
||||
|
||||
#define VD_AGENT_LBUTTON_MASK (1 << 1)
|
||||
#define VD_AGENT_MBUTTON_MASK (1 << 2)
|
||||
#define VD_AGENT_RBUTTON_MASK (1 << 3)
|
||||
#define VD_AGENT_UBUTTON_MASK (1 << 4)
|
||||
#define VD_AGENT_DBUTTON_MASK (1 << 5)
|
||||
#define VD_AGENT_SBUTTON_MASK (1 << 6)
|
||||
#define VD_AGENT_EBUTTON_MASK (1 << 7)
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentMouseState {
|
||||
uint32_t x;
|
||||
uint32_t y;
|
||||
uint32_t buttons;
|
||||
uint8_t display_id;
|
||||
} VDAgentMouseState;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentReply {
|
||||
uint32_t type;
|
||||
uint32_t error;
|
||||
} VDAgentReply;
|
||||
|
||||
enum {
|
||||
VD_AGENT_SUCCESS = 1,
|
||||
VD_AGENT_ERROR,
|
||||
};
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentClipboard {
|
||||
#if 0 /* VD_AGENT_CAP_CLIPBOARD_SELECTION */
|
||||
uint8_t selection;
|
||||
uint8_t __reserved[sizeof(uint32_t) - 1 * sizeof(uint8_t)];
|
||||
#endif
|
||||
uint32_t type;
|
||||
uint8_t data[0];
|
||||
} VDAgentClipboard;
|
||||
|
||||
enum {
|
||||
VD_AGENT_CLIPBOARD_NONE = 0,
|
||||
VD_AGENT_CLIPBOARD_UTF8_TEXT,
|
||||
VD_AGENT_CLIPBOARD_IMAGE_PNG, /* All clients with image support should support this one */
|
||||
VD_AGENT_CLIPBOARD_IMAGE_BMP, /* optional */
|
||||
VD_AGENT_CLIPBOARD_IMAGE_TIFF, /* optional */
|
||||
VD_AGENT_CLIPBOARD_IMAGE_JPG, /* optional */
|
||||
/* identifies a list of absolute paths in phodav server
|
||||
* that is associated with the "org.spice-space.webdav.0" webdav channel;
|
||||
* the items are encoded in UTF-8 and separated by '\0';
|
||||
* the first item must be either "copy" or "cut" (without the quotes)
|
||||
* to indicate what action should be performed with the files that follow */
|
||||
VD_AGENT_CLIPBOARD_FILE_LIST,
|
||||
};
|
||||
|
||||
enum {
|
||||
VD_AGENT_CLIPBOARD_SELECTION_CLIPBOARD = 0,
|
||||
VD_AGENT_CLIPBOARD_SELECTION_PRIMARY,
|
||||
VD_AGENT_CLIPBOARD_SELECTION_SECONDARY,
|
||||
};
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentClipboardGrab {
|
||||
#if 0 /* VD_AGENT_CAP_CLIPBOARD_SELECTION */
|
||||
uint8_t selection;
|
||||
uint8_t __reserved[sizeof(uint32_t) - 1 * sizeof(uint8_t)];
|
||||
#endif
|
||||
#if 0 /* VD_AGENT_CAP_CLIPBOARD_GRAB_SERIAL */
|
||||
uint32_t serial;
|
||||
#endif
|
||||
uint32_t types[0];
|
||||
} VDAgentClipboardGrab;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentClipboardRequest {
|
||||
#if 0 /* VD_AGENT_CAP_CLIPBOARD_SELECTION */
|
||||
uint8_t selection;
|
||||
uint8_t __reserved[sizeof(uint32_t) - 1 * sizeof(uint8_t)];
|
||||
#endif
|
||||
uint32_t type;
|
||||
} VDAgentClipboardRequest;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentClipboardRelease {
|
||||
#if 0 /* VD_AGENT_CAP_CLIPBOARD_SELECTION */
|
||||
uint8_t selection;
|
||||
uint8_t __reserved[sizeof(uint32_t) - 1 * sizeof(uint8_t)];
|
||||
#endif
|
||||
uint8_t dummy_empty_field[0]; /* C/C++ compatibility */
|
||||
} VDAgentClipboardRelease;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentMaxClipboard {
|
||||
int32_t max;
|
||||
} VDAgentMaxClipboard;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentAudioVolumeSync {
|
||||
uint8_t is_playback;
|
||||
uint8_t mute;
|
||||
uint8_t nchannels;
|
||||
uint16_t volume[0];
|
||||
} VDAgentAudioVolumeSync;
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentDeviceDisplayInfo {
|
||||
uint32_t channel_id;
|
||||
uint32_t monitor_id;
|
||||
uint32_t device_display_id;
|
||||
uint32_t device_address_len;
|
||||
uint8_t device_address[0]; /* a zero-terminated string */
|
||||
} VDAgentDeviceDisplayInfo;
|
||||
|
||||
|
||||
/* This message contains the mapping of (channel_id, monitor_id) pair to a
|
||||
* "physical" (virtualized) device and its monitor identified by device_address
|
||||
* and device_display_id.
|
||||
*
|
||||
* It's used on the vd_agent to identify the guest monitors for the
|
||||
* mouse_position and monitors_config messages.
|
||||
*/
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentGraphicsDeviceInfo {
|
||||
uint32_t count;
|
||||
#ifdef _MSC_VER
|
||||
uint8_t display_info[0];
|
||||
#else
|
||||
VDAgentDeviceDisplayInfo display_info[0];
|
||||
#endif
|
||||
} VDAgentGraphicsDeviceInfo;
|
||||
|
||||
|
||||
/* Capabilities definitions
|
||||
*/
|
||||
enum {
|
||||
VD_AGENT_CAP_MOUSE_STATE = 0,
|
||||
VD_AGENT_CAP_MONITORS_CONFIG,
|
||||
VD_AGENT_CAP_REPLY,
|
||||
VD_AGENT_CAP_CLIPBOARD,
|
||||
VD_AGENT_CAP_DISPLAY_CONFIG,
|
||||
VD_AGENT_CAP_CLIPBOARD_BY_DEMAND,
|
||||
VD_AGENT_CAP_CLIPBOARD_SELECTION,
|
||||
VD_AGENT_CAP_SPARSE_MONITORS_CONFIG,
|
||||
VD_AGENT_CAP_GUEST_LINEEND_LF,
|
||||
VD_AGENT_CAP_GUEST_LINEEND_CRLF,
|
||||
VD_AGENT_CAP_MAX_CLIPBOARD,
|
||||
VD_AGENT_CAP_AUDIO_VOLUME_SYNC,
|
||||
VD_AGENT_CAP_MONITORS_CONFIG_POSITION,
|
||||
VD_AGENT_CAP_FILE_XFER_DISABLED,
|
||||
VD_AGENT_CAP_FILE_XFER_DETAILED_ERRORS,
|
||||
VD_AGENT_CAP_GRAPHICS_DEVICE_INFO,
|
||||
VD_AGENT_CAP_CLIPBOARD_NO_RELEASE_ON_REGRAB,
|
||||
VD_AGENT_CAP_CLIPBOARD_GRAB_SERIAL,
|
||||
VD_AGENT_END_CAP,
|
||||
};
|
||||
|
||||
typedef struct SPICE_ATTR_PACKED VDAgentAnnounceCapabilities {
|
||||
uint32_t request;
|
||||
uint32_t caps[0];
|
||||
} VDAgentAnnounceCapabilities;
|
||||
|
||||
#define VD_AGENT_CAPS_SIZE_FROM_MSG_SIZE(msg_size) \
|
||||
(((msg_size) - sizeof(VDAgentAnnounceCapabilities)) / sizeof(uint32_t))
|
||||
|
||||
#define VD_AGENT_CAPS_SIZE ((VD_AGENT_END_CAP + 31) / 32)
|
||||
|
||||
#define VD_AGENT_CAPS_BYTES (((VD_AGENT_END_CAP + 31) / 8) & ~3)
|
||||
|
||||
#define VD_AGENT_HAS_CAPABILITY(caps, caps_size, index) \
|
||||
((index) < (caps_size * 32) && ((caps)[(index) / 32] & (1 << ((index) % 32))))
|
||||
|
||||
#define VD_AGENT_SET_CAPABILITY(caps, index) \
|
||||
{ (caps)[(index) / 32] |= (1 << ((index) % 32)); }
|
||||
|
||||
#define VD_AGENT_CLEAR_CAPABILITY(caps, index) \
|
||||
{ (caps)[(index) / 32] &= ~(1 << ((index) % 32)); }
|
||||
|
||||
#include <spice/end-packed.h>
|
||||
|
||||
#endif /* _H_VD_AGENT */
|
||||
Loading…
Reference in New Issue
Block a user