]>
Commit | Line | Data |
---|---|---|
91406489 | 1 | diff -x aclocal.m4 -x CVS -x configure -x '*.in' -x '*~' -x '*.o' -x '*.a' -x Makefile -x config.h -x config.status -x config.log -x 'stamp-h*' -x '*.Po' -x autom4te.cache -x config.guess -x '.#*' -ruN dosbox-0.61/src/gui/Makefile.am dosbox-0.61+hq2x/src/gui/Makefile.am |
2 | --- dosbox-0.61/src/gui/Makefile.am 2004-07-05 02:44:22.000000000 +0200 | |
3 | +++ dosbox-0.61+hq2x/src/gui/Makefile.am 2004-07-04 23:25:07.000000000 +0200 | |
4 | @@ -3,5 +3,6 @@ | |
5 | noinst_LIBRARIES = libgui.a | |
6 | libgui_a_SOURCES = sdlmain.cpp sdl_mapper.cpp \ | |
7 | render.cpp render_scalers.cpp render_scalers.h render_templates.h \ | |
8 | - midi.cpp midi_win32.h midi_oss.h midi_coreaudio.h midi_alsa.h | |
9 | + midi.cpp midi_win32.h midi_oss.h midi_coreaudio.h midi_alsa.h \ | |
10 | + render_hq2x.cpp render_hq2x.h | |
11 | ||
12 | diff -x aclocal.m4 -x CVS -x configure -x '*.in' -x '*~' -x '*.o' -x '*.a' -x Makefile -x config.h -x config.status -x config.log -x 'stamp-h*' -x '*.Po' -x autom4te.cache -x config.guess -x '.#*' -ruN dosbox-0.61/src/gui/render.cpp dosbox-0.61+hq2x/src/gui/render.cpp | |
13 | --- dosbox-0.61/src/gui/render.cpp 2004-08-05 00:12:58.732847304 +0200 | |
14 | +++ dosbox-0.61+hq2x/src/gui/render.cpp 2004-08-04 23:50:12.000000000 +0200 | |
15 | @@ -33,6 +33,7 @@ | |
16 | #include "support.h" | |
17 | ||
18 | #include "render_scalers.h" | |
19 | +#include "render_hq2x.h" | |
20 | ||
21 | struct PalData { | |
22 | struct { | |
23 | @@ -190,6 +191,9 @@ | |
24 | } | |
25 | break; | |
26 | } | |
27 | + if (render.op.type == OP_Hq2x) { | |
28 | + Hq2x_InitLUTs((void*)render.pal.rgb,render.pal.last,render.pal.first); | |
29 | + } | |
30 | /* Setup pal index to startup values */ | |
31 | render.pal.first=256; | |
32 | render.pal.last=0; | |
33 | @@ -314,6 +318,7 @@ | |
34 | case OP_Interp2x:block=&Interp2x_8;break; | |
35 | case OP_AdvInterp2x:block=&AdvInterp2x_8;break; | |
36 | case OP_TV2x:block=&TV2x_8;break; | |
37 | + case OP_Hq2x:block=&Hq2x_8;break; | |
38 | } | |
39 | gfx_flags=GFX_GetBestMode(block->flags); | |
40 | if (!gfx_flags) { | |
41 | @@ -362,7 +367,7 @@ | |
42 | ||
43 | extern void GFX_SetTitle(Bits cycles, Bits frameskip,bool paused); | |
44 | static void IncreaseFrameSkip(void) { | |
45 | - if (render.frameskip.max<10) render.frameskip.max++; | |
46 | + if (render.frameskip.max<25) render.frameskip.max++; | |
47 | LOG_MSG("Frame Skip at %d",render.frameskip.max); | |
48 | GFX_SetTitle(-1,render.frameskip.max,false); | |
49 | } | |
50 | @@ -376,6 +381,12 @@ | |
51 | void RENDER_Init(Section * sec) { | |
52 | Section_prop * section=static_cast<Section_prop *>(sec); | |
53 | ||
54 | + Hq2x_colourTrigger=section->Get_int("hq2x_threshold"); | |
55 | + if (Hq2x_colourTrigger > 255) Hq2x_colourTrigger = 255; | |
56 | + if (Hq2x_colourTrigger < 0) Hq2x_colourTrigger = 0; | |
57 | + Hq2x_colourTrigger_adaptive=section->Get_int("hq2x_threshold_adaptive"); | |
58 | + if (Hq2x_colourTrigger_adaptive > 255) Hq2x_colourTrigger_adaptive = 255; | |
59 | + if (Hq2x_colourTrigger_adaptive <= 0) Hq2x_colourTrigger_adaptive = 75; | |
60 | render.pal.first=256; | |
61 | render.pal.last=0; | |
62 | render.aspect=section->Get_bool("aspect"); | |
63 | @@ -398,12 +409,17 @@ | |
64 | else if (!strcasecmp(scaler,"advinterp2x")) render.op.want_type=OP_AdvInterp2x; | |
65 | else if (!strcasecmp(scaler,"interp2x")) render.op.want_type=OP_Interp2x; | |
66 | else if (!strcasecmp(scaler,"tv2x")) render.op.want_type=OP_TV2x; | |
67 | + else if (!strcasecmp(scaler,"hq2x")) render.op.want_type=OP_Hq2x; | |
68 | else { | |
69 | render.op.want_type=OP_Normal; | |
70 | LOG_MSG("Illegal scaler type %s,falling back to normal.",scaler); | |
71 | } | |
72 | MAPPER_AddHandler(DecreaseFrameSkip,MK_f7,MMOD1,"decfskip","Dec Fskip"); | |
73 | MAPPER_AddHandler(IncreaseFrameSkip,MK_f8,MMOD1,"incfskip","Inc Fskip"); | |
74 | + MAPPER_AddHandler(Hq2x_DecreaseThreshold,MK_f3,MMOD1|MMOD2,"dechq2xthreshold","Dec Hq2x Static Threshold"); | |
75 | + MAPPER_AddHandler(Hq2x_IncreaseThreshold,MK_f4,MMOD1|MMOD2,"inchq2xthreshold","Inc Hq2x Static Threshold"); | |
76 | + MAPPER_AddHandler(Hq2x_DecreaseThresholdAdaptive,MK_f5,MMOD1|MMOD2,"dechq2xadapthreshold","Dec Hq2x Adaptive Threshold"); | |
77 | + MAPPER_AddHandler(Hq2x_IncreaseThresholdAdaptive,MK_f6,MMOD1|MMOD2,"inchq2xadapthreshold","Inc Hq2x Adaptive Threshold"); | |
78 | GFX_SetTitle(-1,render.frameskip.max,false); | |
79 | } | |
80 | ||
81 | diff -x aclocal.m4 -x CVS -x configure -x '*.in' -x '*~' -x '*.o' -x '*.a' -x Makefile -x config.h -x config.status -x config.log -x 'stamp-h*' -x '*.Po' -x autom4te.cache -x config.guess -x '.#*' -ruN dosbox-0.61/src/gui/render_hq2x.cpp dosbox-0.61+hq2x/src/gui/render_hq2x.cpp | |
82 | --- dosbox-0.61/src/gui/render_hq2x.cpp 1970-01-01 01:00:00.000000000 +0100 | |
83 | +++ dosbox-0.61+hq2x/src/gui/render_hq2x.cpp 2004-08-04 23:43:53.000000000 +0200 | |
84 | @@ -0,0 +1,799 @@ | |
85 | +//hq2x filter demo program | |
86 | +//---------------------------------------------------------- | |
87 | +//Copyright (C) 2003 MaxSt ( maxst@hiend3d.com ) | |
88 |