Re: [Spice-devel] [PATCH 14/20] Use GQueue for RedCharDevice::send_queue

2016-04-15 Thread Jonathon Jongsma
On Thu, 2016-04-14 at 16:50 -0500, Jonathon Jongsma wrote: > From: Christophe Fergeau > > There was an extra RedCharDeviceMsgToClientItem type whose only > purpose was to manage a linked list of items to send. GQueue has the > same purpose as this type in addition to being

Re: [Spice-devel] [PATCH] fix 16 bpp LZ image decompression

2016-04-15 Thread Jonathon Jongsma
On Thu, 2016-04-14 at 17:56 +0100, Frediano Ziglio wrote: > LZ image decompression was broken for 16 bpp: > - stride was computed not computed correctly (as width*4). This caused > also a buffer underflow; FYI: extra "computed" here. Remove the first one. > - stride in pixman is always

[Spice-devel] [PATCH v2] UpgradeItem: use base PipeItem for refcounting

2016-04-15 Thread Jonathon Jongsma
No need to re-implement refcounting in this subclass. However, I needed to add a new 'dcc' member to UpgradeItem to be able to unref properly. --- Changes: - take a reference on dcc in UpgradeItem server/dcc.c | 18 +- server/display-channel.c | 4 +---

Re: [Spice-devel] [PATCH 05/20] dcc: use PipeItem refcounting for ImageItem

2016-04-15 Thread Frediano Ziglio
> > Since the base class now implements refcounting, there's no need to > re-invent it here. > --- > server/dcc-send.c| 4 ++-- > server/dcc.c | 19 +-- > server/dcc.h | 3 +-- > server/display-channel.c | 2 +- > 4 files changed, 9

Re: [Spice-devel] [PATCH 05/20] dcc: use PipeItem refcounting for ImageItem

2016-04-15 Thread Jonathon Jongsma
On Fri, 2016-04-15 at 05:58 -0400, Frediano Ziglio wrote: > > > > Since the base class now implements refcounting, there's no need to > > re-invent it here. > > --- > > server/dcc-send.c| 4 ++-- > > server/dcc.c | 19 +-- > > server/dcc.h | 3

[Spice-devel] [spice] server: Correctly handle and trace stream report errors

2016-04-15 Thread Francois Gouget
We may get stream reports after the stream has been closed, and even, in extreme cases, after a new stream has started reusing the same stream id. Neither case should cause the server to crash. So restore dcc_handle_stream_report() to how it was before being moved to dcc.c. Signed-off-by:

Re: [Spice-devel] [spice-common v3] use specific subdomains for better filtering

2016-04-15 Thread David Jaša
Hi, I like the approach a lot. It seems quite clear and nice to me, but ... On So, 2016-03-12 at 15:32 +0100, Victor Toso wrote: > Hi! I've rebased this series and pushed to my remote branch in > freedesktop [0] [1]. I'll try to clarify the ideia for working on this > and if it does not get any

Re: [Spice-devel] [spice-gtk v3 18/19] log: create subdomains for spice-gtk

2016-04-15 Thread David Jaša
Will it be possible to print all existing subdomains? Or would it be hard to add? On So, 2016-03-12 at 15:32 +0100, Victor Toso wrote: > "audio" : spice-audio.c spice-gstaudio.c spice-pulse.c > "base" : channel-base.c > "channel": spice-channel.c > "coroutine" :

Re: [Spice-devel] [PATCH] fix 16 bpp LZ image decompression

2016-04-15 Thread Pavel Grunt
Hi, On Thu, 2016-04-14 at 17:56 +0100, Frediano Ziglio wrote: > LZ image decompression was broken for 16 bpp: > - stride was computed not computed correctly (as width*4). This > caused >   also a buffer underflow; > - stride in pixman is always multiple of 4 bytes (so for 16 bpp is >  

[Spice-devel] [spice-gtk v4 0/3] Windows Japanese layout workarounds

2016-04-15 Thread Frediano Ziglio
This version contains style change: - remove goto/label; - remove useless default switch. Takao Fujiwara (3): Send Zenkaku_Hankaku key in JP keyboard Send key release event for some keys in JP keyboard Send Hangul key in KR keyboard src/spice-widget.c | 99

[Spice-devel] [spice-gtk v4 2/3] Send key release event for some keys in JP keyboard

2016-04-15 Thread Frediano Ziglio
From: Takao Fujiwara With the previous fix, WM_KEYDOWN of Alt+Zenkaku_Hankaku (VK_KANJI) can be sent with spice-gtk but Alt+Zenkaku_Hankaku does not send the WM_KEYUP event in Windows and it caused Linux desktop freeze with unlimited key press events. The proposed fix is to

[Spice-devel] [spice-gtk v4 1/3] Send Zenkaku_Hankaku key in JP keyboard

2016-04-15 Thread Frediano Ziglio
From: Takao Fujiwara Zenkaku_Hankaku key has the different virtual-key codes between WM_KEYDOWN and WM_KEYUP and MapVirtualKey() cannot get the scancode from virtual-key code of WM_KEYDOWN (VK_DBE_DBCSCHAR) and spice-gtk didn't send the key press events and caused the

[Spice-devel] [spice-gtk v4 3/3] Send Hangul key in KR keyboard

2016-04-15 Thread Frediano Ziglio
From: Takao Fujiwara Korean keyboard assigns Hangul key on the position of Right Alt and Left Alt and Hangul keys have the different scancodes but MapVirtualKey() returned the same scancode and could not use Hangul key on Linux desktop. The fix is to send the right scancode

Re: [Spice-devel] [PATCH 01/20] Add reference counting to PipeItem class

2016-04-15 Thread Pavel Grunt
On Thu, 2016-04-14 at 16:50 -0500, Jonathon Jongsma wrote: > From: Christophe Fergeau > > A user-defined callback is called when the refcount drops to 0. > > Reference counting is manually coded for several classes deriving > from > PipeItem, so this change will help to

Re: [Spice-devel] [PATCH 13/20] Remove use of opaque from vdi_port_read_one_msg_from_device

2016-04-15 Thread Frediano Ziglio
> From: Christophe Fergeau > > We can get 'reds' from the RedCharDevice accessible from the > SpiceCharDeviceInstance passed as an argument. > --- > server/reds.c | 6 -- > 1 file changed, 4 insertions(+), 2 deletions(-) > > diff --git a/server/reds.c b/server/reds.c

Re: [Spice-devel] [PATCH 12/20] Replace RedCharDevice::on_free_self_token with a signal

2016-04-15 Thread Frediano Ziglio
> > From: Christophe Fergeau > > It's more natural to do things this way with glib, and this allows to > remove some coupling between Reds and RedCharDeviceVDIPort. Before this > commit, the RedCharDeviceVDIPort has to provide a on_free_self_token() > because Reds needs to

Re: [Spice-devel] [PATCH 11/20] char-device: Remove RedCharDeviceClass::{un, }ref_msg_to_client

2016-04-15 Thread Frediano Ziglio
> > From: Christophe Fergeau > > Now that client messages are always RedPipeItem, we don't need virtual > functions to know how to ref/unref them. > --- > server/char-device.c | 26 -- > server/char-device.h | 6 ++ > server/reds.c| 14

Re: [Spice-devel] [PATCH 10/20] char-device: Replace RedCharDeviceMsgToClient with PipeItem

2016-04-15 Thread Frediano Ziglio
> > From: Christophe Fergeau > > Now that all derived classes use a type deriving from PipeItem for their > RedCharDeviceMsgToClient, we can make this explicit in the > RedCharDeviceClass vfuncs, and remove the RedCharDeviceMsgToClient > typedef. > --- >

Re: [Spice-devel] [PATCH 09/20] dcc: Use refcounting for MonitorsConfigItem

2016-04-15 Thread Frediano Ziglio
> > --- > server/dcc.c | 25 ++--- > 1 file changed, 10 insertions(+), 15 deletions(-) > > diff --git a/server/dcc.c b/server/dcc.c > index b58a86a..1cd9f1a 100644 > --- a/server/dcc.c > +++ b/server/dcc.c > @@ -510,6 +510,12 @@ void

Re: [Spice-devel] [PATCH 08/20] UpgradeItem: use base PipeItem for refcounting

2016-04-15 Thread Frediano Ziglio
> > No need to re-implement refcounting in this subclass. However, I needed > to add a new 'dcc' member to UpgradeItem to be able to unref properly. > --- > server/dcc.c | 18 +- > server/display-channel.c | 4 +--- > server/display-channel.h | 2 +- >

Re: [Spice-devel] [PATCH 07/20] StreamClipItem: use base class refcounting

2016-04-15 Thread Frediano Ziglio
> > PipeItem already implements refcounting. Use it. > --- > server/dcc.c | 10 +++--- > server/display-channel.c | 4 +--- > server/stream.c | 30 +++--- > server/stream.h | 6 +- > 4 files changed, 20 insertions(+), 30

Re: [Spice-devel] [PATCH 06/20] DrawablePipeItem: use base class for refcounting

2016-04-15 Thread Frediano Ziglio
> > Since PipeItem already implements refcounting, there's no need to > re-implement it here. > --- > server/dcc.c | 26 +- > server/dcc.h | 3 --- > server/display-channel.c | 6 ++ > 3 files changed, 11 insertions(+), 24 deletions(-) > >

Re: [Spice-devel] [PATCH 05/20] dcc: use PipeItem refcounting for ImageItem

2016-04-15 Thread Frediano Ziglio
> > Since the base class now implements refcounting, there's no need to > re-invent it here. > --- > server/dcc-send.c| 4 ++-- > server/dcc.c | 19 +-- > server/dcc.h | 3 +-- > server/display-channel.c | 2 +- > 4 files changed, 9

Re: [Spice-devel] [PATCH 04/20] SpiceVmcPipeItem: use base PipeItem for ref counting

2016-04-15 Thread Frediano Ziglio
> > From: Christophe Fergeau > > This allows to reuse pipe_item_{ref, unref} rather than > reimplementing them in spicevmc.c > --- > server/spicevmc.c | 27 ++- > 1 file changed, 6 insertions(+), 21 deletions(-) > > diff --git a/server/spicevmc.c

Re: [Spice-devel] [PATCH 03/20] smartcard: Use base PipeItem for MsgItem refcounting

2016-04-15 Thread Frediano Ziglio
> > From: Christophe Fergeau > > This allows to reuse pipe_item_{ref, unref} rather than > reimplementing them in smartcard.c > --- > server/smartcard.c | 35 --- > 1 file changed, 12 insertions(+), 23 deletions(-) > > diff --git

Re: [Spice-devel] [PATCH 02/20] reds: Derive VDIPortReadBuf from PipeItem

2016-04-15 Thread Frediano Ziglio
> > From: Christophe Fergeau > > Since PipeItem is already refcounted, this allows to remove various > layers of ref/unref helpers from reds.c, and use the generic > pipe_item_{ref, unref} instead. > --- > server/reds.c | 74 >

Re: [Spice-devel] [spice-gtk 1/3] Send Zenkaku_Hankaku key in JP keyboard

2016-04-15 Thread Frediano Ziglio
I copy the same note on https://bugzilla.redhat.com/show_bug.cgi?id=1311858 for reference: The ImmDisableIME patch is not necessary only if you have the grab of the keyboard. This as the windows hook which is installed when you have the keyboard grabbed receives the messages before IME change

Re: [Spice-devel] [spice-gtk v3 1/3] Send Zenkaku_Hankaku key in JP keyboard

2016-04-15 Thread Takao Fujiwara
I confirmed v3 works fine. On 04/14/16 19:52, Frediano Ziglio-san wrote: > From: Takao Fujiwara > > Zenkaku_Hankaku key has the different virtual-key codes between WM_KEYDOWN > and WM_KEYUP and MapVirtualKey() cannot get the scancode from virtual-key > code of WM_KEYDOWN

Re: [Spice-devel] [spice-gtk 1/3] Send Zenkaku_Hankaku key in JP keyboard

2016-04-15 Thread Takao Fujiwara
It seems my debug log of libgdk-win32-2.0-0.dll caused a conflicted IO and SEGV. After I deleted my debug log, I no longer encounter SEGV so now ImmDisableIME.patch is not necessary. Thanks, Fujiwara On 04/12/16 20:08, Takao Fujiwara-san wrote: I mean ImmDisableIME.patch should be used as a

[Spice-devel] [spice-gtk v3 3/3] Send Hangul key in KR keyboard

2016-04-15 Thread Takao Fujiwara
Korean keyboard assigns Hangul key on the position of Right Alt and Left Alt and Hangul keys have the different scancodes but MapVirtualKey() returned the same scancode and could not use Hangul key on Linux desktop. The fix is to send the right scancode of VK_HANGUL. ---  src/spice-widget.c | 10

[Spice-devel] [spice-gtk v3 2/3] Send key release event for some keys in JP keyboard

2016-04-15 Thread Takao Fujiwara
With the previous fix, WM_KEYDOWN of Alt+Zenkaku_Hankaku (VK_KANJI) can be sent with spice-gtk but Alt+Zenkaku_Hankaku does not send the WM_KEYUP event in Windows and it caused Linux desktop freeze with unlimited key press events. The proposed fix is to send the key release event in spice-gtk.

Re: [Spice-devel] [PATCH spice-gtk 2/2] channel-main: Move variable to block where is needed

2016-04-15 Thread Christophe Fergeau
Acked-by: Christophe Fergeau On Thu, Apr 14, 2016 at 06:01:24PM +0200, Pavel Grunt wrote: > --- > src/channel-main.c | 5 + > 1 file changed, 1 insertion(+), 4 deletions(-) > > diff --git a/src/channel-main.c b/src/channel-main.c > index a7770fa..604f333 100644 > ---

Re: [Spice-devel] [PATCH spice-gtk 1/2] channel-main: Add helper function for getting audio

2016-04-15 Thread Christophe Fergeau
Acked-by: Christophe Fergeau On Thu, Apr 14, 2016 at 06:01:23PM +0200, Pavel Grunt wrote: > Avoid repeating the same code and having a SpiceSession variable > defined when is not really needed. > --- > src/channel-main.c | 17 + > 1 file changed, 9

[Spice-devel] how can i get a tool to test the spice performance eg:image quality, video fps

2016-04-15 Thread 纪列全
Hi guys, I have used the spice long time, now I want to compare the spice protocol to others, such as ICA、PCoIP,but I have not a tool or method to test the performance of spice, could you help me? Thanks in advance. Ji lie quan ___