diff options
author | Sebastian Geerken <devnull@localhost> | 2013-09-10 21:00:58 +0200 |
---|---|---|
committer | Sebastian Geerken <devnull@localhost> | 2013-09-10 21:00:58 +0200 |
commit | 06f5833b8f41196bc427c06e39ed21d431c1e665 (patch) | |
tree | 17654b3a7449ffdcfae9916fc211d5750789dfad /src/imgbuf.cc | |
parent | 6acc9e9c711bad1f9d0125d884b9993ed1c4789e (diff) |
Some refactoring: the image decoding code now only accesses dw::core::ImgRenderer, not dw::Image (which now implements the former) anymore.
Diffstat (limited to 'src/imgbuf.cc')
-rw-r--r-- | src/imgbuf.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/imgbuf.cc b/src/imgbuf.cc index 16eb5c31..48e6bde5 100644 --- a/src/imgbuf.cc +++ b/src/imgbuf.cc @@ -90,10 +90,9 @@ void a_Imgbuf_unref(void *v_imgbuf) /* * Create a new Imgbuf */ -void *a_Imgbuf_new(void *v_dw, int img_type, uint_t width, uint_t height, +void *a_Imgbuf_new(void *layout, int img_type, uint_t width, uint_t height, double gamma) { - Layout *layout = ((Widget*)v_dw)->getLayout(); if (!layout) { MSG_ERR("a_Imgbuf_new: layout is NULL.\n"); exit(1); @@ -104,7 +103,8 @@ void *a_Imgbuf_new(void *v_dw, int img_type, uint_t width, uint_t height, linebuf = (uchar_t*) dRealloc(linebuf, linebuf_size); } - return (void*)layout->createImgbuf(Imgbuf::RGB, width, height, gamma); + return (void*)((Layout*)layout)->createImgbuf(Imgbuf::RGB, width, height, + gamma); } /* |