aboutsummaryrefslogtreecommitdiffstats
path: root/common/rfb/PixelBuffer.h
diff options
context:
space:
mode:
authorPierre Ossman <ossman@cendio.se>2014-01-30 17:57:27 +0100
committerPierre Ossman <ossman@cendio.se>2014-07-07 14:50:29 +0200
commit2e5a10608394186fd1324c97b17d7f08e0c0aaf6 (patch)
treebdd76744f7d2d68bceb9b662c7ab85478510cdd7 /common/rfb/PixelBuffer.h
parentff9eb5a949f7af0198db8c563a7d9d735ad083c3 (diff)
downloadtigervnc-2e5a10608394186fd1324c97b17d7f08e0c0aaf6.tar.gz
tigervnc-2e5a10608394186fd1324c97b17d7f08e0c0aaf6.zip
Get rid of getStride()
It was confusing and not properly used everywhere. Callers should use the stride they get when they get the buffer pointer.
Diffstat (limited to 'common/rfb/PixelBuffer.h')
-rw-r--r--common/rfb/PixelBuffer.h8
1 files changed, 3 insertions, 5 deletions
diff --git a/common/rfb/PixelBuffer.h b/common/rfb/PixelBuffer.h
index 94230247..59d71c79 100644
--- a/common/rfb/PixelBuffer.h
+++ b/common/rfb/PixelBuffer.h
@@ -1,4 +1,5 @@
/* Copyright (C) 2002-2005 RealVNC Ltd. All Rights Reserved.
+ * Copyright 2014 Pierre Ossman for Cendio AB
*
* This is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -93,14 +94,10 @@ namespace rfb {
class FullFramePixelBuffer : public PixelBuffer {
public:
FullFramePixelBuffer(const PixelFormat& pf, int width, int height,
- rdr::U8* data_);
+ rdr::U8* data, int stride);
virtual ~FullFramePixelBuffer();
public:
- // - Get the number of pixels per row in the actual pixel buffer data area
- // This may in some cases NOT be the same as width().
- virtual int getStride() const;
-
// Get a pointer to specified pixel data
virtual const rdr::U8* getBuffer(const Rect& r, int* stride) {
return getBufferRW(r, stride);
@@ -134,6 +131,7 @@ namespace rfb {
FullFramePixelBuffer();
rdr::U8* data;
+ int stride;
};
// -=- Managed pixel buffer class