diff options
author | Constantin Kaplinsky <const@tightvnc.com> | 2007-09-03 04:23:48 +0000 |
---|---|---|
committer | Constantin Kaplinsky <const@tightvnc.com> | 2007-09-03 04:23:48 +0000 |
commit | d7c0a6d4adf9bede1722f2f6bbbb440ecd31d692 (patch) | |
tree | e25b0b3736f2102435282136cd9cdd1ac7f9144a | |
parent | 560ded4e568b23812d0198041663d2c4967bbb32 (diff) | |
download | tigervnc-d7c0a6d4adf9bede1722f2f6bbbb440ecd31d692.tar.gz tigervnc-d7c0a6d4adf9bede1722f2f6bbbb440ecd31d692.zip |
Sending updates for "video area".
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@2331 3789f03b-4d11-0410-bbf8-ca57d06f2519
-rw-r--r-- | common/rfb/VNCSConnectionST.cxx | 4 | ||||
-rw-r--r-- | common/rfb/VNCServer.h | 3 | ||||
-rw-r--r-- | common/rfb/VNCServerST.h | 1 |
3 files changed, 6 insertions, 2 deletions
diff --git a/common/rfb/VNCSConnectionST.cxx b/common/rfb/VNCSConnectionST.cxx index 5237c1b4..d6541f97 100644 --- a/common/rfb/VNCSConnectionST.cxx +++ b/common/rfb/VNCSConnectionST.cxx @@ -646,9 +646,7 @@ void VNCSConnectionST::writeFramebufferUpdate() // complicated as compared to the original VNC4. writer()->setupCurrentEncoder(); int nRects = (ui.copied.numRects() + - /* FIXME: Sending video area is not yet enabled. (ui.video_area.is_empty() ? 0 : 1) + - */ (drawRenderedCursor ? 1 : 0)); std::vector<Rect> rects; std::vector<Rect>::const_iterator i; @@ -659,6 +657,8 @@ void VNCSConnectionST::writeFramebufferUpdate() } writer()->writeFramebufferUpdateStart(nRects); + if (!ui.video_area.is_empty()) + writer()->writeVideoRect(server->getPixelBuffer(), ui.video_area); Region updatedRegion; writer()->writeRects(ui, &image_getter, &updatedRegion); updates.subtract(updatedRegion); diff --git a/common/rfb/VNCServer.h b/common/rfb/VNCServer.h index df0fb0e5..1e7acc63 100644 --- a/common/rfb/VNCServer.h +++ b/common/rfb/VNCServer.h @@ -35,6 +35,9 @@ namespace rfb { // protocol messages being sent, or clients being disconnected. virtual void setPixelBuffer(PixelBuffer* pb) = 0; + // getPixelBuffer() returns a pointer to the PixelBuffer object. + virtual PixelBuffer* getPixelBuffer() const = 0; + // setColourMapEntries() tells the server that some entries in the colour // map have changed. The server will retrieve them via the PixelBuffer's // ColourMap object. This may result in protocol messages being sent. diff --git a/common/rfb/VNCServerST.h b/common/rfb/VNCServerST.h index 37b75eaf..fad8cb93 100644 --- a/common/rfb/VNCServerST.h +++ b/common/rfb/VNCServerST.h @@ -79,6 +79,7 @@ namespace rfb { // Methods overridden from VNCServer virtual void setPixelBuffer(PixelBuffer* pb); + virtual PixelBuffer* getPixelBuffer() const { return pb; } virtual void setColourMapEntries(int firstColour=0, int nColours=0); virtual void serverCutText(const char* str, int len); virtual void add_changed(const Region ®ion); |