summaryrefslogtreecommitdiff
path: root/mbone/vic/patches/patch-av
diff options
context:
space:
mode:
Diffstat (limited to 'mbone/vic/patches/patch-av')
-rw-r--r--mbone/vic/patches/patch-av24
1 files changed, 18 insertions, 6 deletions
diff --git a/mbone/vic/patches/patch-av b/mbone/vic/patches/patch-av
index deb842de2e4..b21f10651b9 100644
--- a/mbone/vic/patches/patch-av
+++ b/mbone/vic/patches/patch-av
@@ -1,8 +1,8 @@
-$NetBSD: patch-av,v 1.1 2002/08/16 16:56:01 agc Exp $
+$NetBSD: patch-av,v 1.2 2006/02/27 15:49:56 joerg Exp $
---- color-mono.cc 2002/08/16 16:49:05 1.1
-+++ color-mono.cc 2002/08/16 16:49:31
-@@ -200,7 +200,7 @@
+--- color-mono.cc.orig 1995-11-14 02:14:31.000000000 +0000
++++ color-mono.cc
+@@ -200,7 +200,7 @@ public:
~MonoColorModel();
virtual int alloc_grays();
virtual int command(int argc, const char*const* argv);
@@ -11,12 +11,24 @@ $NetBSD: patch-av,v 1.1 2002/08/16 16:56:01 agc Exp $
private:
int white_;
};
-@@ -250,7 +250,7 @@
+@@ -243,14 +243,17 @@ typedef void (MonoWindowRenderer::*MonoM
+ class MonoWindowRenderer : public WindowDitherer {
+ public:
+ MonoWindowRenderer(VideoWindow* vw, int decimation, MonoColorModel& cm) :
+- WindowDitherer(vw, decimation), cm_(cm) { }
++ WindowDitherer(vw, decimation), cm_(cm), method_(NULL) { }
+ void render(const u_char* frm, int off, int x, int w, int h) {
+- (this->*method_)(frm, off, x, w, h);
++ if (this->method_)
++ (this->*method_)(frm, off, x, w, h);
++ else
++ dither_null(frm, off, x, w, h);
+ }
protected:
MonoColorModel& cm_;
virtual void update();
- virtual void disable() { method_ = WindowDitherer::dither_null; }
-+ virtual void disable() { method_ = &WindowDitherer::dither_null; }
++ virtual void disable() { method_ = NULL; }
MonoMethod method_;
void dither(const u_char* frm, u_int off, u_int x,
u_int width, u_int height) const;