Re: [Spice-devel] How to build spice vdagent for win32?

2018-05-24 Thread Pencc
Hi > > Hello, everyone! >       I build spice vdagent as [1] in fedora28, but it failed as > [2], I'm a truly newbie in windows, > that's helped if I can get some document or a build flow.  > > [1] > # sudo apt-get install mingw-w64-x86-64 mingw64-filesystem > mingw64-

Re: [Spice-devel] [PATCH spice-common] fixup! meson build

2018-05-24 Thread Eduardo Lima (Etrunko)
On 24/05/18 12:53, Jonathon Jongsma wrote: > On Thu, 2018-05-24 at 12:41 -0300, Eduardo Lima (Etrunko) wrote: >> On 24/05/18 12:31, Jonathon Jongsma wrote: >>> On Wed, 2018-05-23 at 15:23 -0300, Eduardo Lima (Etrunko) wrote: On 23/05/18 11:43, Frediano Ziglio wrote: >> >> Signed-off-by

Re: [Spice-devel] [spice-server] sound: Don't mute recording when client reconnects

2018-05-24 Thread Christophe Fergeau
On Thu, May 24, 2018 at 05:06:19AM -0400, Frediano Ziglio wrote: > > > > On Wed, May 23, 2018 at 01:36:35PM -0400, Frediano Ziglio wrote: > > > Testing this, so far is working correctly: > > > > > > Subject: [PATCH spice-server] rcc: Make red_channel_client_is_connected > > > return > > > correc

[Spice-devel] [PATCH spice-common v2 2/2] lz: Inline GET_{r, g, b} macros

2018-05-24 Thread Frediano Ziglio
With last changes are just used once and are straight forward. Signed-off-by: Frediano Ziglio Acked-by: jonathon Jongsma --- common/lz_compress_tmpl.c | 13 + 1 file changed, 1 insertion(+), 12 deletions(-) Changes since v1: - rebased. diff --git a/common/lz_compress_tmpl.c b/comm

[Spice-devel] [PATCH spice-common v2 1/2] lz: Optimise SAME_PIXEL for RGB16

2018-05-24 Thread Frediano Ziglio
Do not extract all components and compare one by one, can be easily compared together. Performance measurements on a set of 16 bit images shown an improve of about 10%. Signed-off-by: Frediano Ziglio --- common/lz_compress_tmpl.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) Cha

Re: [Spice-devel] [spice-server 1/2] worker: Use more local vars in dev_create_primary_surface

2018-05-24 Thread Frediano Ziglio
> > On Thu, May 24, 2018 at 09:35:16AM -0400, Frediano Ziglio wrote: > > > > > > On Thu, May 24, 2018 at 08:39:49AM -0400, Frediano Ziglio wrote: > > > > > > > > > > There's already a 'display' variable equal to worker->display_channel > > > > > which is not consistently used. This commit also a

Re: [Spice-devel] [spice-server 1/2] worker: Use more local vars in dev_create_primary_surface

2018-05-24 Thread Christophe Fergeau
On Thu, May 24, 2018 at 09:35:16AM -0400, Frediano Ziglio wrote: > > > > On Thu, May 24, 2018 at 08:39:49AM -0400, Frediano Ziglio wrote: > > > > > > > > There's already a 'display' variable equal to worker->display_channel > > > > which is not consistently used. This commit also adds a new 'chan

Re: [Spice-devel] [PATCH spice-common 2/3] lz: Optimise SAME_PIXEL for RGB16

2018-05-24 Thread Jonathon Jongsma
On Thu, 2018-05-24 at 07:38 -0400, Frediano Ziglio wrote: > > > > On Thu, 2018-05-10 at 13:03 -0400, Frediano Ziglio wrote: > > > > > > > > On Wed, 2018-05-09 at 14:10 +0100, Frediano Ziglio wrote: > > > > > Do not extract all components and compare one by one, can be > > > > > easily > > > > > c

Re: [Spice-devel] [PATCH spice-common] fixup! meson build

2018-05-24 Thread Jonathon Jongsma
On Thu, 2018-05-24 at 12:41 -0300, Eduardo Lima (Etrunko) wrote: > On 24/05/18 12:31, Jonathon Jongsma wrote: > > On Wed, 2018-05-23 at 15:23 -0300, Eduardo Lima (Etrunko) wrote: > > > On 23/05/18 11:43, Frediano Ziglio wrote: > > > > > > > > > > Signed-off-by: Eduardo Lima (Etrunko) > > > > > --

Re: [Spice-devel] [PATCH spice-common] fixup! meson build

2018-05-24 Thread Eduardo Lima (Etrunko)
On 24/05/18 12:31, Jonathon Jongsma wrote: > On Wed, 2018-05-23 at 15:23 -0300, Eduardo Lima (Etrunko) wrote: >> On 23/05/18 11:43, Frediano Ziglio wrote: Signed-off-by: Eduardo Lima (Etrunko) --- meson.build | 14 ++ meson_options.txt | 5 + 2

Re: [Spice-devel] [PATCH spice-common] fixup! meson build

2018-05-24 Thread Jonathon Jongsma
On Wed, 2018-05-23 at 15:23 -0300, Eduardo Lima (Etrunko) wrote: > On 23/05/18 11:43, Frediano Ziglio wrote: > > > > > > Signed-off-by: Eduardo Lima (Etrunko) > > > --- > > > meson.build | 14 ++ > > > meson_options.txt | 5 + > > > 2 files changed, 15 insertions(+), 4 del

[Spice-devel] [PATCH spice-common] quic: Remove some too strict asserts in hot paths

2018-05-24 Thread Frediano Ziglio
Some assert in the code are doing some paranoid test and in code paths quite hot. The encoding time is reduced by 30-50% while the decoding time is reduced by a 20-30%. Signed-off-by: Frediano Ziglio --- common/quic.c | 20 ++-- common/quic_family_tmpl.c | 4 +++- 2

Re: [Spice-devel] [spice-server 1/2] worker: Use more local vars in dev_create_primary_surface

2018-05-24 Thread Frediano Ziglio
> > On Thu, May 24, 2018 at 08:39:49AM -0400, Frediano Ziglio wrote: > > > > > > There's already a 'display' variable equal to worker->display_channel > > > which is not consistently used. This commit also adds a new 'channel' > > > local variable to remove upcasts to RedChannel. > > > > Not ent

Re: [Spice-devel] [spice-server 1/2] worker: Use more local vars in dev_create_primary_surface

2018-05-24 Thread Christophe Fergeau
On Thu, May 24, 2018 at 08:39:49AM -0400, Frediano Ziglio wrote: > > > > There's already a 'display' variable equal to worker->display_channel > > which is not consistently used. This commit also adds a new 'channel' > > local variable to remove upcasts to RedChannel. > > Not entirely true, chann

[Spice-devel] [vdagent-win PATCH] Avoid to use names with reserved characters.

2018-05-24 Thread Frediano Ziglio
Some characters are reserved and should not be used in Windows independently by the file system used. This avoid to use paths in the filename which could lead to some nasty hacks (like names like "..\hack.txt"). The return statement cause the file transfer to be aborted with VD_AGENT_FILE_XFER_STAT

Re: [Spice-devel] [PATCH spice-common] fixup! meson build

2018-05-24 Thread Eduardo Lima (Etrunko)
On 23/05/18 17:15, Frediano Ziglio wrote: >> >> Signed-off-by: Eduardo Lima (Etrunko) >> --- >> meson.build | 14 ++ >> meson_options.txt | 5 + >> 2 files changed, 15 insertions(+), 4 deletions(-) >> >> diff --git a/meson.build b/meson.build >> index 9d44604..cd75c51 10064

Re: [Spice-devel] How to build spice vdagent for win32?

2018-05-24 Thread Frediano Ziglio
> Hello, everyone! > I build spice vdagent as [1] in fedora28, but it failed as [2], I'm a truly > newbie in windows, > that's helped if I can get some document or a build flow. > [1] > # sudo apt-get install mingw-w64-x86-64 mingw64-filesystem > mingw64-cximage-static mingw64-jasper-static mingw6

[Spice-devel] [vdagent-win PATCH] vdagent: Removed unused declaration

2018-05-24 Thread Frediano Ziglio
Signed-off-by: Frediano Ziglio --- vdagent/vdagent.cpp | 1 - 1 file changed, 1 deletion(-) diff --git a/vdagent/vdagent.cpp b/vdagent/vdagent.cpp index f00fbf5..0a364df 100644 --- a/vdagent/vdagent.cpp +++ b/vdagent/vdagent.cpp @@ -99,7 +99,6 @@ private: void dispatch_message(VDAgentMessag

Re: [Spice-devel] [spice-server 1/2] worker: Use more local vars in dev_create_primary_surface

2018-05-24 Thread Frediano Ziglio
> > There's already a 'display' variable equal to worker->display_channel > which is not consistently used. This commit also adds a new 'channel' > local variable to remove upcasts to RedChannel. Not entirely true, channel is initialized doing the upcast, so there's still the upcast. I would move

Re: [Spice-devel] [spice-server 2/2] worker: Remove display_is_connected()

2018-05-24 Thread Frediano Ziglio
> > It's only called once, and when it's called, we will have dereferenced > worker->display_channel a few lines before, so this cannot be NULL. The > if (worker->display_channel) check can thus be removed, so > display_is_connected() becomes just red_channel_is_connected(). > > Signed-off-by: Ch

[Spice-devel] How to build spice vdagent for win32?

2018-05-24 Thread pengyixiang
Hello, everyone! I build spice vdagent as [1] in fedora28, but it failed as [2], I'm a truly newbie in windows, that's helped if I can get some document or a build flow. [1] # sudo apt-get install mingw-w64-x86-64 mingw64-filesystem mingw64-cximage-static mingw64-jasper-static mingw64-li

Re: [Spice-devel] [PATCH spice-common 2/3] lz: Optimise SAME_PIXEL for RGB16

2018-05-24 Thread Frediano Ziglio
> > On Thu, 2018-05-10 at 13:03 -0400, Frediano Ziglio wrote: > > > > > > On Wed, 2018-05-09 at 14:10 +0100, Frediano Ziglio wrote: > > > > Do not extract all components and compare one by one, can be > > > > easily > > > > compared together. > > > > > > Do you have some data about how performan

[Spice-devel] [spice-server 2/2] worker: Remove display_is_connected()

2018-05-24 Thread Christophe Fergeau
It's only called once, and when it's called, we will have dereferenced worker->display_channel a few lines before, so this cannot be NULL. The if (worker->display_channel) check can thus be removed, so display_is_connected() becomes just red_channel_is_connected(). Signed-off-by: Christophe Fergea

[Spice-devel] [spice-server 1/2] worker: Use more local vars in dev_create_primary_surface

2018-05-24 Thread Christophe Fergeau
There's already a 'display' variable equal to worker->display_channel which is not consistently used. This commit also adds a new 'channel' local variable to remove upcasts to RedChannel. Signed-off-by: Christophe Fergeau --- server/red-worker.c | 8 1 file changed, 4 insertions(+), 4 d

Re: [Spice-devel] [spice-server] sound: Don't mute recording when client reconnects

2018-05-24 Thread Frediano Ziglio
> > On Wed, May 23, 2018 at 01:36:35PM -0400, Frediano Ziglio wrote: > > Testing this, so far is working correctly: > > > > Subject: [PATCH spice-server] rcc: Make red_channel_client_is_connected > > return > > correct information during initialization > > > > Use stream->watch as flag to check

Re: [Spice-devel] [spice-server] sound: Don't mute recording when client reconnects

2018-05-24 Thread Christophe Fergeau
On Wed, May 23, 2018 at 01:36:35PM -0400, Frediano Ziglio wrote: > Testing this, so far is working correctly: > > Subject: [PATCH spice-server] rcc: Make red_channel_client_is_connected return > correct information during initialization > > Use stream->watch as flag to check if connected or not

Re: [Spice-devel] [spice-server] sound: Don't mute recording when client reconnects

2018-05-24 Thread Victor Toso
Hi, Just to mention that I tested both patches and they work as expected in the situation around rhbz#1549132 toso On Wed, May 23, 2018 at 01:36:35PM -0400, Frediano Ziglio wrote: > > > When a new record channel is added, the code relies on a > > > snd_send() call in record_channel_clien