aboutsummaryrefslogtreecommitdiffstats
path: root/console.h
diff options
context:
space:
mode:
authoraliguori <aliguori@c046a42c-6fe2-441c-8c8c-71466251a162>2008-11-24 19:29:13 +0000
committeraliguori <aliguori@c046a42c-6fe2-441c-8c8c-71466251a162>2008-11-24 19:29:13 +0000
commit0e1f5a0c495dd7a5c72c9321a29541bdde8f423a (patch)
tree374c5da7054c16f764a1cb2b5079d612cf417dac /console.h
parentcab3bee2d6f1d6eb6ad74006b8a63562cda9ba4d (diff)
Introduce accessors for DisplayState (Stefano Stabellini)
Introducing some accessors: ds_get_linesize ds_get_bits_per_pixel ds_get_width ds_get_height ds_get_data Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5789 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'console.h')
-rw-r--r--console.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/console.h b/console.h
index fba9e299b..6ee40cc2a 100644
--- a/console.h
+++ b/console.h
@@ -114,6 +114,31 @@ static inline void dpy_cursor(DisplayState *s, int x, int y)
s->dpy_text_cursor(s, x, y);
}
+static inline int ds_get_linesize(DisplayState *ds)
+{
+ return ds->linesize;
+}
+
+static inline uint8_t* ds_get_data(DisplayState *ds)
+{
+ return ds->data;
+}
+
+static inline int ds_get_width(DisplayState *ds)
+{
+ return ds->width;
+}
+
+static inline int ds_get_height(DisplayState *ds)
+{
+ return ds->height;
+}
+
+static inline int ds_get_bits_per_pixel(DisplayState *ds)
+{
+ return ds->depth;
+}
+
typedef unsigned long console_ch_t;
static inline void console_write_ch(console_ch_t *dest, uint32_t ch)
{